Skip to content

Update all attributes in NWM postprocessing outputs to match current v 3.0 products - [NGWPC 11631] - #36

Merged
sivasankkar merged 11 commits into
developmentfrom
nwm_attributes_11631_sselvanathan
Aug 20, 2026
Merged

Update all attributes in NWM postprocessing outputs to match current v 3.0 products - [NGWPC 11631]#36
sivasankkar merged 11 commits into
developmentfrom
nwm_attributes_11631_sselvanathan

Conversation

@sivasankkar

Copy link
Copy Markdown

This PR makes updates to the variable attributes and encoding from templating to combined NWM products. This involves removing xarray generated keys (such as Fill value, chunk sizes) that may conflict with NWM products. The workflow was updated to carry over the NWM attributes right from the templating stage. Other bugs with dimensions of crs variable, feature_ids not adding up in the combined product were also addressed.

Additions

Removals

Changes

  • consts.py: added reservoir_assimilated_value to ignored variables list. Added netcdf4 and xarray encoding keys as a list.
  • NetCdfProductionManager.py: Added the configuration (cycle type) as a parameter to NOMADs downloads so that it downloads only the user requested products. Assigned the requested cycle as a DataProcessor class variable for easy retrieval throughout the code.
  • DataProcessor.py: Added requested cycle as a class variable. Added function to copy the global attributes from the NOMADs reference files to the products. Ensured that the variable attributes are also copied over through all intermediate steps in the post-processing workflow all the way to the combined products. Fixed bugs with crs and time variables to desirable formats.
  • utils.py: Added function to copy variable attributes. Updated download function to download only requested products.

Testing

  1. Tested with VPU 3N and 3S for CONUS. Alaska, PR and HI dataset for oCONUS.

Screenshots

Notes

Todos

Checklist

  • PR has an informative and human-readable title
  • Changes are limited to a single goal (no scope creep)
  • Code can be automatically merged (no conflicts)
  • Code follows project standards (link if applicable)
  • Passes all existing automated tests
  • Any change in functionality is tested
  • New functions are documented (with a description, list of inputs, and expected output)
  • Placeholder code is flagged / future todos are captured in comments
  • Visually tested in supported browsers and devices (see checklist below 👇)
  • Project documentation has been updated (including the "Unreleased" section of the CHANGELOG)
  • Reviewers requested with the Reviewers tool ➡️

Testing checklist

Target Environment support

  • Windows
  • Linux
  • Browser

Accessibility

  • Keyboard friendly
  • Screen reader friendly

Other

  • Is useable without CSS
  • Is useable without JS
  • Flexible from small to large screens
  • No linting errors or warnings
  • JavaScript tests are passing

@jswade-rtx

Copy link
Copy Markdown

I completed the following postprocessing tests using this branch:

CONUS: short range, AnA, medium range mem1, long range mem1
Alaska: short range, AnA
Hawaii: short_range, AnA
Puerto Rico: short range, AnA

@sivasankkar
sivasankkar merged commit c46347a into development Aug 20, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants