Is your feature request related to a problem? Please describe.
We're using Julia types as dtypes, but a third-party library does np.dtype(jl_type). Maybe there's a way to support this as an upstream feature for everyone.
Describe the solution you'd like
Ideally, I'd like something like an implementation of the __numpy_dtype__ protocol or supported Julia types. This could even be implemented on some kinds of structs.
Describe alternatives you've considered
Maybe we could solve this upstream by converting back and forth, but a simple conversion is always helpful.
Additional context
Originally reported by @ilan-gold and @amalia-k510 in pydata/sparse#915
Is your feature request related to a problem? Please describe.
We're using Julia types as dtypes, but a third-party library does
np.dtype(jl_type). Maybe there's a way to support this as an upstream feature for everyone.Describe the solution you'd like
Ideally, I'd like something like an implementation of the
__numpy_dtype__protocol or supported Julia types. This could even be implemented on some kinds of structs.Describe alternatives you've considered
Maybe we could solve this upstream by converting back and forth, but a simple conversion is always helpful.
Additional context
Originally reported by @ilan-gold and @amalia-k510 in pydata/sparse#915