Skip to content

Conversation

mgharamti
Copy link
Contributor

Description:

This PR introduces an interface to USGS's new hydrologic model "pywatershed". The PR also includes an observation converter that supports assimilating streamflow gauges, including USGS's recent next-generation water observing system (NGWOS) sensors.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update

Documentation changes needed?

  • My change requires a change to the documentation.
    • I have updated the documentation accordingly.

Tests

I've run all model_mod_check tests. I've also run several filter experiments

Checklist for merging

  • Updated changelog entry
  • Documentation updated
  • Update conf.py

Checklist for release

  • Merge into main
  • Create release from the main branch with appropriate tag
  • Delete feature-branch

Testing Datasets

Testing dataset can be found here: /glade/work/gharamti/DART/usgs_hydro/models/pywatershed/work

mgharamti and others added 30 commits March 11, 2025 20:27
Created a new model and added necessary testing files
including network parameters and sample restarts
Added model namelist parameters in the input.nml
and modified the model_mod.f90 accordingly. Also,
did some clean-up of the model_mod
Added geometry files and started populating static_init_model
Added logic to manage active domains
Added channel and hru domains.
Also, defined and coded all connectivity information
including the relationship between streamflow and HRUs
model_mod is almost complete!
Added:
- GSMD
- GC
- PMC
- RMT

Also, read lon of segments from shapefile and added them
to geometry file to be used for constructing connectivity
structure.
The function can be run in Matlab only once for
any DA experiment. It will create an appended geometry
file with teh necessary Routelike-style variables.
I've also done some cleaning of the model-mod.
Tested filter with two sets of obs_seq files, assimilating
1 and 2 obs. Both serial and parallel runs of filter
gave the same exact results. Also, cleaned up the
directories and screated a scripts dir.
Fixed typo and reset the debug flag
Started documentation by adding readme.rst file
Added pywatershed to the list of supported models
Added rotuines for converting USGS streamflow observations.
The program 'create_identity_streamflow_obs' is heavily based
on the already available USGS converter. It adds new capabilities
such as: identity obs evaluation and unit conversion. Note that
the new program is needed because the filing structure and network
in pywatershed in different than wrf_hydro
On top of append_seg_data.m, I now added a python function
with the same functionality .. better fitting with the
HydroDART workflow.
Going from reading integer gauge IDs into characters.
This would remove the need to pad the strings with '0'
Used the mask array to simplify get_close when
adding the contributing groundwater basins
Included another check on the HRUs while executing
ATS localization. This now makes sure the individual
close HRUs are active.
Indexing into the type of HRUs was incorrectly
specified. It was using the full state index to
access arrays within the HRU domain only.
After reading model time, the file was not
being closed. This caused an error when
overwriting the update on the same input
ensemble files.
Matlab-based diagnostic scripts for pws-dart experiments.
- pwsDARTdiags.m assembles the data from obs_diag_output and obs_epoch netCDF files
  and creates ensemble time-series plots
- summary_diags_pws.m summarizes all results into boxplots and saves the prior
  and posterior statistics into text files
- run_pwsDARTdiags.m calls pwsDARTdiags.m with a specified configuration
- Updated the streamflow file with the instantaneous
  streamflow. The previous file used the daily averaged streamflow
- Modified the input.nml to reflect the usage of the new streamflow
- Fixed a bug in the diag scripts that prevented the analysis on
  certain gauges.
These come in after fully testing the system and completing 6-months
worth of assimilation.
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.

1 participant