Accelerating Scientific Computing in Python with Numba: A Real-World Example
summary
Shows a real pipeline: compare C (clang -O3) assembly to Python compiled with Numba JIT via LLVM IR and inspect_asm, then solve a 10M-point irregular time series max-over-24h problem. Naive Python runs 3h43m, adding Numba drops it to 235s (~57×); switching to a linear MaxQueue (two-stack) algorithm yields ~50s, and converting classy code to procedural Numba-typed functions finishes in 11s (≈1251× speedup).
AI-written summary · about
chapters (17)
- 0:00Introduction to Numba
- 2:35Interpreted vs compiled code
- 3:47Python internals and Numba
- 5:14The role of LLVM
- 7:06Implementing Numba
- 8:05Numba best practices
- 9:30Assembly and performance
- 10:37Analyzing execution loops
- 11:43Performance benchmarks
- 14:09Case study: Time series data
- 15:21Optimizing with Numba
- 17:10Algorithmic improvements
- 19:04Linear solution strategy
- 19:55Refining code for Numba
- 20:39Maxizing final efficiency
- 21:35Final results and takeaways
- 22:14Conclusion
related talks
22mSupercharge Scientific Computing in Python with Numba
37mUsing Numba Effectively Today
33mLet's Run Python on a Supercomputer!
30mNumba, a JIT compiler for fast numerical code
01h 33mPower up your work with compiling and profiling
42mMaking your code faster: Cython and parallel processing in the Jupyter Notebook
02h 28mGPU Accelerated Python
32mJulia for Pythonistas
