Skip to content

Feat cbh updates#37

Merged
pnorton-usgs merged 6 commits intodevelopmentfrom
feat_cbh_updates
Jun 10, 2025
Merged

Feat cbh updates#37
pnorton-usgs merged 6 commits intodevelopmentfrom
feat_cbh_updates

Conversation

@pnorton-usgs
Copy link
Copy Markdown
Member

Add functionality to improve handling of legacy naming of CBH variable names. The variables are now standardized according to currently PRMS 5.2.1.1 CBH variable naming.

ASCII CBH files will have their variable renamed if needed and if possible to the current standards. If the new variable names can be used then additional metadata becomes available to view and/or write to netCDF attributes.

NetCDF CBH files are read as-is. If writing to a netCDF file the existing variables/attributes will be written. If writing to an ASCII file the variable will be renamed if possible to the current standard name.

- Removed precip, tmax, tmin. These were never official CBH variable names.
- Changed version for hru_ppt, tmax_hru and tmin_hru to 5.0.0.
- Added version to all CBH variables.
- enforce official CBH variable names for ASCII format when control object is supplied.
- fix _FillValue error when writing to netCDF format and metadata is missing.
- rename var_src property to cbh_src.
- _cbh_to_xarray() now expects a dictionary of filepaths and variable names instead of a list of file paths.
@pnorton-usgs pnorton-usgs self-assigned this Jun 10, 2025
@pnorton-usgs pnorton-usgs merged commit 98b1709 into development Jun 10, 2025
14 checks passed
@pnorton-usgs pnorton-usgs deleted the feat_cbh_updates branch June 10, 2025 14:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant