Lisp for the Win Gbor Melis @GaborMelis | http://quotenil.com | - - PowerPoint PPT Presentation

lisp for the win
SMART_READER_LITE
LIVE PREVIEW

Lisp for the Win Gbor Melis @GaborMelis | http://quotenil.com | - - PowerPoint PPT Presentation

I NTRODUCTION S ELF A PPLY W RAPUP Lisp for the Win Gbor Melis @GaborMelis | http://quotenil.com | mega@retes.hu Franz Inc. 2014 May 6 @GaborMelis Franz Inc. I NTRODUCTION S ELF A PPLY W RAPUP W HAT S THIS ? @GaborMelis Franz Inc. I


slide-1
SLIDE 1

INTRODUCTION SELF APPLY WRAPUP

Lisp for the Win

Gábor Melis

@GaborMelis | http://quotenil.com | mega@retes.hu

Franz Inc.

2014 May 6

@GaborMelis Franz Inc.

slide-2
SLIDE 2

INTRODUCTION SELF APPLY WRAPUP

WHAT’S THIS?

@GaborMelis Franz Inc.

slide-3
SLIDE 3

INTRODUCTION SELF APPLY WRAPUP

SETTING OUT

@GaborMelis Franz Inc.

slide-4
SLIDE 4

INTRODUCTION SELF APPLY WRAPUP

THE QUICK CLIMB

Your tools shape your thoughts, be careful what you pick.

@GaborMelis Franz Inc.

slide-5
SLIDE 5

INTRODUCTION SELF APPLY WRAPUP

THE SWEET SPOT

From thought to code ideas descend on an uneven staircase.

@GaborMelis Franz Inc.

slide-6
SLIDE 6

INTRODUCTION SELF APPLY WRAPUP

HIGHLANDS

Lisp, the ultimate prototyping language. (defmacro defsection (name docstring) ‘(defun ,name () ,docstring))

@GaborMelis Franz Inc.

slide-7
SLIDE 7

INTRODUCTION SELF APPLY WRAPUP

HIGHLANDS

(defsection @pax-basics "Now let’s examine the most important pieces in detail. See the DEFSECTION macro, *DISCARD-DOCUMENTATION-P*, and the DOCUMENT function.")

@GaborMelis Franz Inc.

slide-8
SLIDE 8

INTRODUCTION SELF APPLY WRAPUP

HIGHLANDS

(defsection @pax-basics "Now let’s examine the most important pieces in detail." defsection *discard-documentation-p* document)

@GaborMelis Franz Inc.

slide-9
SLIDE 9

INTRODUCTION SELF APPLY WRAPUP

HIGHLANDS

(defsection @pax-basics "Now let’s examine the most important pieces in detail." (defsection macro) (*discard-documentation-p* variable) (document function))

@GaborMelis Franz Inc.

slide-10
SLIDE 10

INTRODUCTION SELF APPLY WRAPUP

HIGHLANDS

The versatile M-. works in docstrings and code: "See generic-function FOO." "See [FOO][generic-function]." (generic-function foo) (foo generic-function) (foo (method () (t string t))) (foo compiler-macro)

@GaborMelis Franz Inc.

slide-11
SLIDE 11

INTRODUCTION SELF APPLY WRAPUP

HIGHLANDS

PAX highlights:

◮ DEFSECTION: A place for the narrative ◮ DEFSECTION: Export in logical groups ◮ Automatic linking and markup of code in generated

documentation

◮ SLIME’s M-. goes where the link does ◮ Extensible

@GaborMelis Franz Inc.

slide-12
SLIDE 12

INTRODUCTION SELF APPLY WRAPUP

STUCK ON THE FLAT

What to change?

@GaborMelis Franz Inc.

slide-13
SLIDE 13

INTRODUCTION SELF APPLY WRAPUP

STUCK ON THE FLAT

What to change?

  • 1. The code (Hex: RL -> electric circuit)

@GaborMelis Franz Inc.

slide-14
SLIDE 14

INTRODUCTION SELF APPLY WRAPUP

STUCK ON THE FLAT

What to change?

  • 1. The code (Hex: RL -> electric circuit)
  • 2. The tools (Tron: C++ -> Lisp)

@GaborMelis Franz Inc.

slide-15
SLIDE 15

INTRODUCTION SELF APPLY WRAPUP

STUCK ON THE FLAT

What to change?

  • 1. The code (Hex: RL -> electric circuit)
  • 2. The tools (Tron: C++ -> Lisp)
  • 3. The methodology (Planet Wars: notes, PAX)

@GaborMelis Franz Inc.

slide-16
SLIDE 16

INTRODUCTION SELF APPLY WRAPUP

STUCK ON THE FLAT

What to change?

  • 1. The code (Hex: RL -> electric circuit)
  • 2. The tools (Tron: C++ -> Lisp)
  • 3. The methodology (Planet Wars: notes, PAX)
  • 4. You (Sleep, exercise)

@GaborMelis Franz Inc.

slide-17
SLIDE 17

INTRODUCTION SELF APPLY WRAPUP

WHAT’S THIS?

@GaborMelis Franz Inc.

slide-18
SLIDE 18

INTRODUCTION SELF APPLY WRAPUP

WHAT’S THIS?

@GaborMelis Franz Inc.

slide-19
SLIDE 19

INTRODUCTION SELF APPLY WRAPUP

WHAT’S THIS?

@GaborMelis Franz Inc.

slide-20
SLIDE 20

INTRODUCTION SELF APPLY WRAPUP

A LONG WAY FROM HOME

CPU GPU Distributed Execution BLAS CUBLAS MAT Gaussian Processes Backprop Networks Boltzmann Machines SVD SVM Lots of Algos Improved GC Cookie Cutter API Data Frames @GaborMelis Franz Inc.

slide-21
SLIDE 21

INTRODUCTION SELF APPLY WRAPUP

FOCUS ON THE CARROT

CPU GPU Distributed Execution BLAS CUBLAS MAT Gaussian Processes Backprop Networks Boltzmann Machines SVD SVM Lots of Algos Improved GC Cookie Cutter API Data Frames @GaborMelis Franz Inc.

slide-22
SLIDE 22

INTRODUCTION SELF APPLY WRAPUP

ARE WE THERE YET?

CPU GPU Distributed Execution BLAS CUBLAS MAT Gaussian Processes Backprop Networks Boltzmann Machines SVD SVM Lots of Algos Improved GC Cookie Cutter API Data Frames @GaborMelis Franz Inc.

slide-23
SLIDE 23

INTRODUCTION SELF APPLY WRAPUP

AH, IT’S THE TRAINING WHEELS

(make-mat ’(2 3) :initial-contents ’((1 2 3) (4 5 6))) => #<MAT 2x3 AB #2A((1.0d0 2.0d0 3.0d0) (4.0d0 5.0d0 6.0d0))>

@GaborMelis Franz Inc.

slide-24
SLIDE 24

INTRODUCTION SELF APPLY WRAPUP

AH, IT’S THE TRAINING WHEELS

(scal! 2 *) => #<MAT 2x3 AB #2A((2.0d0 4.0d0 6.0d0) (8.0d0 10.0d0 12.0d0))>

@GaborMelis Franz Inc.

slide-25
SLIDE 25

INTRODUCTION SELF APPLY WRAPUP

AH, IT’S THE TRAINING WHEELS

(with-cuda () (print (scal! -1 *))) #<MAT 2x3 abC #2A((-2.0d0 -4.0d0 -6.0d0) (-8.0d0 -10.0d0 -12.0d0))> => #<MAT 2x3 AB #2A((-2.0d0 -4.0d0 -6.0d0) (-8.0d0 -10.0d0 -12.0d0))>

@GaborMelis Franz Inc.

slide-26
SLIDE 26

INTRODUCTION SELF APPLY WRAPUP

AH, IT’S THE TRAINING WHEELS

MAT features:

◮ API similar to normal lisp arrays ◮ Automatic synchronization of lisp, foreign and cuda

memory

◮ BLAS, CUBLAS, CURAND support ◮ Foreign arrays: pinning, static or dynamic allocation ◮ Extensible with new facet types ◮ Implemented on top of the CUBE library

@GaborMelis Franz Inc.

slide-27
SLIDE 27

INTRODUCTION SELF APPLY WRAPUP

THE FUTURE OF LISP SCIENTIFIC COMPUTING

CPU GPU Distributed Execution BLAS CUBLAS MAT Gaussian Processes Backprop Networks Boltzmann Machines SVD SVM Lots of Algos Improved GC Cookie Cutter API Data Frames @GaborMelis Franz Inc.

slide-28
SLIDE 28

INTRODUCTION SELF APPLY WRAPUP

STUCK ON THE FLAT

@GaborMelis Franz Inc.

slide-29
SLIDE 29

INTRODUCTION SELF APPLY WRAPUP

STUCK ON THE FLAT

  • 1. Uninterested? Pick a task with a combination of rewards.

@GaborMelis Franz Inc.

slide-30
SLIDE 30

INTRODUCTION SELF APPLY WRAPUP

STUCK ON THE FLAT

  • 1. Uninterested? Pick a task with a combination of rewards.
  • 2. Lazy? Make sure there is a continuous stream of

improvements to make.

@GaborMelis Franz Inc.

slide-31
SLIDE 31

INTRODUCTION SELF APPLY WRAPUP

STUCK ON THE FLAT

  • 1. Uninterested? Pick a task with a combination of rewards.
  • 2. Lazy? Make sure there is a continuous stream of

improvements to make.

  • 3. Too few? Make it easy for users and other developers to

join.

@GaborMelis Franz Inc.

slide-32
SLIDE 32

INTRODUCTION SELF APPLY WRAPUP

WRAPUP

personal growth production exploration exploitation libraries applications cooperation competition

@GaborMelis Franz Inc.

slide-33
SLIDE 33

INTRODUCTION SELF APPLY WRAPUP

WRAPUP

https://github.com/melisgl/mgl-pax https://github.com/melisgl/mgl-mat

@GaborMelis Franz Inc.