-
Notifications
You must be signed in to change notification settings - Fork 25
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
Split up and remove offsetting from cc.querying.getvar #148
Conversation
@aidanheerdegen Andy has mentioned that he's willing to test this. How would we best go about making it available in the Conda environment? Can we build one out of the branch, or would it have to hit master and be tagged first? |
It is certainly possible to build it out of a branch, but if you want automatic builds and uploading to https://anaconda.org/coecms then it is master and tagged that does this. it doesn't get deployed to the conda environments automatically, so you can tag it with a |
Ok. I have pinned |
OK, will do that tomorrow. But I might need more instruction on how to create that environment... |
With the advances in xarray, we have ended up duplicating some of its functionality. Paring down the data to a certain time range can be done on the resulting DataArray, and rebasing the times is less necessary due to more intuitive handling of CFTimes. If rebasing is required, it's available separately.
After a bit of a battle with tags and conda, I have figured out how to get a beta tag into the conda channel. @AndyHoggANU you should be able to test this (finally)! |
I have made a little repo you can clone with instructions for installing a test environment @AndyHoggANU https://github.com/aidanheerdegen/cc-test |
Hi @angus-g and @aidanheerdegen I managed to get Aidan's test environment working to test this version out. Note that xarray couldn't find matplotlib in this test environment, so I couldn't verify my tests by plotting the output, but I did verify that all the listed arguments worked as they should, for a few different datasets. I think this is ready to go in, Let me know once it's there as I'll have to modify my scripts to do the offsetting separately. |
Any objections if I merge this? @AndyHoggANU? |
Yes please!! |
See #147 for motivation behind this change. As concluded there, we can't offload everything to
open_mfdataset
, so restriction of the returned file set based on start/end time and overall number of files is retained.This should be a drop-in change, although offsetting will have to be done as a separate step.
It may be worth merging #129 first (or at least in conjunction with this), because it gives the range of available times for a given variable, in the calendar/units of the files (which are used for the querying).
Closes #143, closes #136, closes #135, closes #113.