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
numpy (and similar data objects that share its API, such as dask, cfdm.Data) reasonably allow subspaces to have size 0 axes:
numpy
dask
cfdm.Data
>>> import numpy as np >>> a = np.arange(9) >>> a[[False] * 9] array([], dtype=int64)
At cfdm v1.10.0.0, cfdm constructs also allow this:
v1.10.0.0
>>> import cfdm >>> f = cfdm.example_field(0) >>> f.shape (5, 8) >>> f[[False] * 5] <Field: specific_humidity(latitude(0), longitude(8)) 1>
... but they shouldn't, because it is not allowed by the CF data model. I.e. in the above example, f[[False] * 5] should raise an exception.
f[[False] * 5]
PR to follow.
The text was updated successfully, but these errors were encountered:
Successfully merging a pull request may close this issue.
numpy
(and similar data objects that share its API, such asdask
,cfdm.Data
) reasonably allow subspaces to have size 0 axes:At cfdm
v1.10.0.0
, cfdm constructs also allow this:... but they shouldn't, because it is not allowed by the CF data model. I.e. in the above example,
f[[False] * 5]
should raise an exception.PR to follow.
The text was updated successfully, but these errors were encountered: