Skip to content
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

Netcdf4 update #47

Merged
merged 2 commits into from
May 10, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,11 @@ This project adheres to [Semantic Versioning](http://semver.org/).
- Added Vertical TEC Instrument
- Added documentation
- Bug Fix
- Updated madrigal methods to simplify compound data types and enable
creation of netCDF4 files using `Instrument.to_netcdf4()`.
- Updated Madrigal methods to simplify compound data types and enable
creation of netCDF4 files using `Instrument.to_netcdf4()`
- Updated load for multiple files in pandas format
- Fixed remote listing routine to return filenames instead of experiments
- Fixed bug introduced by change in xarray requiring engine kwarg

## [0.0.3] - 2020-06-15
- pypi compatibility
Expand Down
5 changes: 3 additions & 2 deletions pysatMadrigal/instruments/methods/general.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,9 +91,10 @@ def load(fnames, tag=None, inst_id=None, xarray_coords=[], file_type='hdf5'):
if file_type == "netCDF4":
# Xarray natively opens netCDF data into a Dataset
if len(fnames) == 1:
file_data = xr.open_dataset(fnames[0])
file_data = xr.open_dataset(fnames[0], engine="netcdf4")
else:
file_data = xr.open_mfdataset(fnames, combine='by_coords')
file_data = xr.open_mfdataset(fnames, combine='by_coords',
engine="netcdf4")

# Currently not saving file header data, as all metadata is at
# the data variable level
Expand Down