Numba lightning

1,520 views

Published on

0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
1,520
On SlideShare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
19
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • Numba lightning

    1. 1. NumbaNumPy-aware dynamic Python compiler Lightning Talk Travis E. Oliphant PyData NYC October 27, 2012
    2. 2. Motivation• Python is great for rapid development and high-level thinking-in-code• It is slow for interior loops because lack of type information leads to a lot of indirection and “extra” code.
    3. 3. Motivation• NumPy users have a lot of type information --- but only currently have one-size fits all pre-compiled, vectorized loops.• Many new features envisioned will need the ability for high-level expressions to be compiled to machine code.
    4. 4. Goal: rapid iteration and development + fast code execution Numba should be the world’s best array-oriented compiler.
    5. 5. NumPy + Mamba = Numba Python Function Machine Code LLVM-PY LLVM Library ISPC OpenCL OpenMP CUDA CLANG Intel AMD Nvidia Apple ARM
    6. 6. Example Numba@jit(‘f8(f8)’)def sinc(x): if x==0.0: return 1.0 else: return sin(x*pi)/(pi*x)
    7. 7. Status and Future• My early bytecode branch further developed by Jon Riehl (Resilient Science) sponsored by Continuum Analytics, Inc. --- interprets bytecode directly• Current trunk works with AST directly and making rapid progress - Mark Florrison (minivect) - Siu Kwan Lam (pymothoa)
    8. 8. Demo
    9. 9. RoadMap• Numba 0.2 available now• Github trunk has many changes -- 0.3 will support - structures - Python code - objects with inheritance Check out NumbaPro for cutting-edge features
    10. 10. Software Stack Future? Plateaus of Code re-use + DSLs SQL R TDPL Matlab Python OBJC C FORTRAN C++ LLVM
    11. 11. Join Us! http://numba.pydata.org https://store.continuum.io/cshop/numbapro

    ×