-
Notifications
You must be signed in to change notification settings - Fork 40
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
Fix : for a added feature in weather-mv to extract specific date's data from zarr files. #400
Conversation
@@ -311,6 +315,10 @@ def expand(self, paths): | |||
xarray_open_dataset_kwargs = self.xarray_open_dataset_kwargs.copy() | |||
xarray_open_dataset_kwargs.pop('chunks') | |||
ds, chunks = xbeam.open_zarr(self.first_uri, **xarray_open_dataset_kwargs) | |||
|
|||
if self.start_date is not None and self.end_date is not None: |
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.
Would this be useful for non-Zarr datasets? I'm on the fence.
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.
The PR: #396 is useful for the non-zarr datasets and this PR will be working on zarr datasets.
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.
SGTM.
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.
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.
After the last nit is fixed, this is good to go.
As mentioned in PR #396 I have added a feature in weather-mv which can allows users to access data for a specific date from zarr files but that is not working properly.
BQ ingestion of zarr data is done through the
expand function
and in this function we can't get value ofstart_date
andend_date
fromxarray_open_dataset_kwargs
dict. So I added this code, using of we get the value ofstart_date
&end_date
from thezarr_kwargs
.