stefanv/growcut_py — pull request #2 by ahmadia (2013-04-13 20:15:36+00:00)
Title: numba-accelerated growcut kernels

This pull request provides a new file:

`_growcut_numba.py`

that provides a numba-accelerated version of growcut. The numba-accelerated growcut is 1000x faster than a pure Python implementation, and of comparable speed to the tuned Cython implementation (on my OS X.8 Intel Core i7 laptop, the Numba implementation is slightly more than 2x as fast as the Cython implementation, excluding compilation times).

The Cython and Python implementations were adjusted slightly to account for a small modification to the algorithm discussed with @stefanv. The full growcut algorithm is currently not being verified/validated, this needs to be amended before upstreaming this code to growcut_py.

This code has been built and tested against a [recent development version of Numba](https://github.com/numba/numba/commit/46d88f6a820402e3a10488aa3e624ab562f115d1). You may have difficulty with the currently released version of Numba. Please report any difficulties with the install process or crashes to me [or the Numba team](https://github.com/numba/numba/issues).