Comments

Python loops over arrays are extremely slow
NumPy vectorization may be sufficient
However, NumPy vectorization may be inconvenient
- plain loops in Fortran/C/C++ are much easier
Write administering code in Python
Identify bottlenecks (via profiling)
Migrate slow Python code to Fortran, C, or C++
Python-Fortran w/NumPy arrays via F2PY: easy
Python-C/C++ w/NumPy arrays via SWIG: not that easy,
handwritten wrapper code is most common

previousnexttable of contents