grackle-project / grackle

The Grackle chemistry and cooling library for astrophysical simulations and models.
Other
26 stars 50 forks source link

Remove the lone `cimport numpy` line #224

Closed mabruzzo closed 3 months ago

mabruzzo commented 3 months ago

This should let us drop numpy as a build-time requirement. This involved a minor edit to the get_field c-function written in grackle_wrapper.pyx (we now use Cython's built-in typed memory-view functionality instead. While I was there, I made a minor tweak to the function so that it will perform proper error-checking for a plausible failure-mode.

I have not actually modified setup.py to remove numpy from the list of build-requirements. I quickly tried to do that, but got an opaque setuptools-related error. I decided not to deal with this since we are transitioning to scikit-build-core.