Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update modflow input files with calibrated values. #458

Closed
DStrom1987 opened this issue Sep 1, 2023 · 7 comments
Closed

Update modflow input files with calibrated values. #458

DStrom1987 opened this issue Sep 1, 2023 · 7 comments

Comments

@DStrom1987
Copy link

Hi,

I'm struggling a bit with how to update my modflow files with the parameters from my final pest run or from a set of acceptable results in an ensamble run.

I use to do this with parrep in the pest utilities. Is there a way of doing this if you want to run the optimized model outside of the python shell?

Sincerely
David

@jtwhite79
Copy link
Collaborator

you can still use parrep with .base.par file that ies writes each iteration, either with pyemu or with the parrep utility (assuming the format of the .par file hasnt changed in PEST recently...). If you want a realization other than base, then you'll need to do something more clever to extract that parameter vector from the ensemble file and get it into a control file.

Once you have the desired par values into the control file, then the standard noptmax=0 run will gen the underlying model input and output files - same as it ever was...

@DStrom1987
Copy link
Author

Right.. Ill give it another go. I'm not entirely sure what went wrong. But as I have used a simplifyed workflow (being an avid gui user) where all inputs and outputs including. pst-file, pilotpoints etc were generated by model muse, the Kx parameter field following a pest run ends up in a subfolder called "array" where the output to this folder is written by plproc using the RunModel.bat after preparing the .pst-file with the latest .par-file using parrep.
This workflow has been working fine with the old pest-site, but for whatever reason the kx-array remains unchanged.

@briochh
Copy link
Collaborator

briochh commented Mar 27, 2024

@DStrom1987, did you get to the bottom of this issue? If not it would be good to get a bit more detail, on what you are trying to achieve, what steps you are taking, and what is going wrong.

@DStrom1987
Copy link
Author

Hi,

Thanks for asking. I managed achieve what I wanted by following Jeremys advice and some hints in other threads.

The step I’m trying to achieve is in itself quite obsolete really. Its just that I’m not coming from a programing background and still rely quite heavily on GUIs. Which is why I needed to be able to read in the posterior parameters into model muse.

I realize it kind of defeats the purpose of running ensembles if I’m still picking out a few good members of the posterior. For this reason I’m nog working on another workflow where I can run the posterior ensemble with pestpp-swp output heads of my posterior and some predictive case of interest to compare head outputs and get an ensemble of drawdown contours.

getting there slowly.. but I’m still struggling since I cant follow the steps of the tutorials regarding pst_from with a quadtree grid.

the tools are great though!

Sincerely
David

@briochh
Copy link
Collaborator

briochh commented Mar 27, 2024

If you are happy to dig around in the pyemu library there is a pst_from test that works with a quadtree version of freyberg, here (thanks due to @rhugman-intera). It might not perfectly match your usage but there may be some tricks in there. @rhugman-intera, is there a quadtree demo notebook anywhere?

Being able to view resultant fields is definitely an important step, for both sense checking and communications. There is work to be done making this easier with ensemble outputs.

Will close this issue now.

@briochh briochh closed this as completed Mar 27, 2024
@DStrom1987
Copy link
Author

DStrom1987 commented Mar 27, 2024 via email

@briochh
Copy link
Collaborator

briochh commented Mar 27, 2024

pstfrom should accept none structured flopy model grid object (subject to maintaining inter-dependancies!). This may be linked to #466.

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

No branches or pull requests

3 participants