-
Notifications
You must be signed in to change notification settings - Fork 281
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
Cellmethod tolerance #5126
base: main
Are you sure you want to change the base?
Cellmethod tolerance #5126
Conversation
f"NetCDF variable cell_methods of {nc_cell_methods!r} " | ||
"contains no valid cell methods." | ||
) | ||
warnings.warn(msg, UserWarning) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this should be an Error
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well I disagree, for all the reasons listed there.
I think it's just unhelpful to refuse to load a file, if the problem can be stepped around.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In order to work with data from ESGF, it is important for ESMValTool that we can load malformed data and correct the iris cube after loading the bits that are fine. The alternatives are less attractive:
- Copy the malformed file, fix it and then load that with iris. This is computationally very inefficient because it requires a lot of writing to disk.
- Use xarray to load the malformed file, fix the issues, and convert the DataArray to an iris cube. This would be a good alternative if the conversion reliably worked.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also recalling this passionate appeal ...
#4506 (comment)
!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But... we are really serious now about the approach (2.) "Use xarray ... convert"
Relating to #4994, proposals are still working up : see here
Current status : I have functional code, and we have pretty much decided now on a plan...
- set up a separate scitools repo
- generic python classes for handling netcdf-data
- free+fast conversion between these and any of : netcdf file data / iris cubes / xarray datasets
Frankly though, this will take a while to establish properly : I have as yet no home repo, no tests written + plenty of other priorities getting in the way.
Addresses #5119