You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a modelscript up and running for a specific model extent.
However, when I change the model extent so that several boundary condition definitions completely fall outside the model extent. The packages that configure those boundary conditions should not be added to the MF6 simulation.
For example
I am configuring the well package and depending on the extent I select, wells need to be configured or not. In the current implementation and all wells fall outside the extent, nlmod gladly configures via flopy a well-package with stress-period-data of length 0. No problem so far. However when we write and run the simulation results in the following error:
Resources Software User Rights Notice for complete use, copyright,
and distribution information.
Run start date and time (yyyy/mm/dd hh:mm:ss): 2024/04/08 10:58:44
Writing simulation list file: mfsim.lst
Using Simulation name file: mfsim.nam
ERROR REPORT:
1. Required block "DIMENSIONS" not found. Found end of file instead.
UNIT ERROR REPORT:
1. Error occurred while reading file
'/workspaces/NHFLO/models/modelscripts/09pwnmodel2/model_ws/pwn_gwt.cnc'
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/workspaces/nlmod/build/__editable__.nlmod-0.7.2-py3-none-any/nlmod/sim/sim.py", line 63, in write_and_run
assert sim.run_simulation(silent=silent)[0], "Modflow run not succeeded"
AssertionError: Modflow run not succeeded
The same error message comes from zero-length stress-period-data for the CNC package.
Desired behavior
Zero-length stress-period-data does not result in the crashing of MF6.
Solution
Should we replace a zero-length stree-period-data with None in all the package creation routines? Would that solve our problem? (results in cnc.stress_period_data.data is None)
Alternatively, if the length of the stress-period-data is zero, don't create the flopy package.
Or, in the nlmod.sim.write_and_run(sim, ds) function, remove packages from the simulation that have zero-length stress-period-data.
The error message given by mf6 is not so helpfull..
The text was updated successfully, but these errors were encountered:
Checking for zero length stress_period_data makes sense to me. The least we should do is log a warning, but I think it also makes sense to prevent the package from being added/created in that situation.
I have a modelscript up and running for a specific model extent.
However, when I change the model extent so that several boundary condition definitions completely fall outside the model extent. The packages that configure those boundary conditions should not be added to the MF6 simulation.
For example
I am configuring the well package and depending on the extent I select, wells need to be configured or not. In the current implementation and all wells fall outside the extent, nlmod gladly configures via flopy a well-package with stress-period-data of length 0. No problem so far. However when we write and run the simulation results in the following error:
The same error message comes from zero-length stress-period-data for the CNC package.
Desired behavior
Zero-length stress-period-data does not result in the crashing of MF6.
Solution
Should we replace a zero-length stree-period-data with(results inNone
in all the package creation routines? Would that solve our problem?cnc.stress_period_data.data is None
)nlmod.sim.write_and_run(sim, ds)
function, remove packages from the simulation that have zero-length stress-period-data.The error message given by mf6 is not so helpfull..
The text was updated successfully, but these errors were encountered: