We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
BTW I recently discovered you can specify shape too, although most of numpy returns `shape=Any` so it's of limited use at the mo:
ScalarType_co = TypeVar("ScalarType_co", bound=np.generic, covariant=True) OneDArray = np.ndarray[tuple[int], np.dtype[ScalarType_co]] TwoDArray = np.ndarray[tuple[int, int], np.dtype[ScalarType_co]] NPMask = OneDArray[np.bool]
Originally posted by @coretl in #143 (comment)
We can specify dimensional constraints in numpy.typing, so npt.NDArray[tuple[int, int], np.floating[Any]] for example.
numpy.typing
npt.NDArray[tuple[int, int], np.floating[Any]]
There are probably specific places in scanspec where this would be useful, this issue is go through and find them.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Originally posted by @coretl in #143 (comment)
We can specify dimensional constraints in
numpy.typing
, sonpt.NDArray[tuple[int, int], np.floating[Any]]
for example.There are probably specific places in scanspec where this would be useful, this issue is go through and find them.
The text was updated successfully, but these errors were encountered: