-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
More robust/flexible numpy dtype and ufuncs #52
Comments
I also assume that it will require numpy>=2? It might certainly be nice to at some point use a custom user-defined numpy dtype, instead of the object dtype that can hold anything. But the current setup works quite OK I think (and you get a nice error message if some value in the object array is not a Geography), so I would also say to first focus on getting a minimal viable package with the current approach, and we can always improve this later. |
Not sure about that, the commit I linked above is from 6 years ago. I also don't really know whether there would be a more elegant, numpy 2 solution nowadays.
Yes definitely! Just wanted to link this here as a useful reference in case we might eventually need it. The ufunc feature is also relevant (perhaps more than user dtypes) to work around the limitations of |
Ah, I hadn't checked the date of the commit ;) I am also not entirely sure if the custom dtype already supports object dtype (I know when we explored an initial version of it two years ago for shapely, that wasn't yet the case) |
Not sure that we need this now, but here is an implementation of Numpy user dtypes and ufuncs with pybind11.
The text was updated successfully, but these errors were encountered: