MODFLOW-USGS / modflow6

USGS Modular Hydrologic Model
https://modflow6.readthedocs.io/
Other
255 stars 117 forks source link

PRT FMI mishandles array-based RCH/EVT input #2042

Open wpbonelli opened 3 weeks ago

wpbonelli commented 3 weeks ago

The PRT flow model interface does not properly handle array-based recharge/evapotranspiration package input if the model grid has an inactive region. The package's nodelist may contain zeroes in this case (corresponding to inactive cells), while PRT FMI currently assumes nodelist elements are all nonzero, causing a crash.

Reported by @mnfienen. Related to #2041.

langevin-usgs commented 3 weeks ago

Is this just for PRT-FMI and not GWT/GWE?

wpbonelli commented 3 weeks ago

I can only speak to PRT at the moment, but happy to check the other models when I'm back from leave. @jdhughes-usgs or @emorway-usgs may have more insight

langevin-usgs commented 3 weeks ago

I can only speak to PRT at the moment, but happy to check the other models when I'm back from leave. @jdhughes-usgs or @emorway-usgs may have more insight

I'll look into it. Enjoy your leave!

emorway-usgs commented 3 weeks ago

I've tried a couple approaches to reproduce the problem. First I'll mention that the large "regional" model that @mnfienen shared with @wpbonelli was shared with me. Running it, I confirmed that it errored out. Second, I commented out the PRT model and confirmed that the GWF model would run to completion (~1.5 minutes for me w/o PRT active). Third, I generated a minimal set of GWT input to test whether its FMI package also would terminate with the same error (attached). It did not - although GWT didn't converge (but that's secondary, more importantly the FMI package didn't bomb). Since the GWT FMI package didn't bomb, it may be possible to trace the bug by contrasting which index in PRT fails but yet doesn't cause problems with GWT.

rcha-troubleshoot.zip