A Python class to export Modflow 2005 model 3D geometry and parameters to Vtk – Tutorial

Hydrate

Generating 3D visualizations of groundwater models is essential to analyze the flow regime, perform quality checks and see the interaction of the groundwater body with external factors / boundary conditions. The Flopy library has tools to export the parameters, boundary conditions and results that we have modified and compiled within a Python class. The use of this class allows the generation of Vtk files on a friendly way and in few steps. The tutorial also includes a representation of the parameters generated in ParaView.

We have another Python class for Modflow 6 model available on this link.

Tutorial

Code

from workingTools import Mf2005VtkGenerator
# load model for examples
namFile = "ModelWebinar1d.nam"
modelWs = "../Model/"
exeName = "../Bin/"
vtkDir = "../Vtk"
vtkGen = Mf2005VtkGenerator(namFile=namFile,
                         modelWs=modelWs,
                         exeName=exeName,
                         vtkDir=vtkDir)
#load model
vtkGen.loadModel()
Check for files in '../Vtk'.
Deleted file: ../VtkmodelGeometry.vtk
Deleted file: ../VtkmodelParameters.vtk
Deleted file: ../Vtkparam_hk.npy
Deleted file: ../Vtkparam_ibound.npy
Deleted file: ../Vtkparam_ss.npy
Deleted file: ../Vtkparam_strt.npy
Deleted file: ../Vtkparam_sy.npy
Deleted file: ../Vtkparam_vka.npy

All files in '../Vtk' have been deleted.



C:Userssaulmanaconda3Libsite-packagesflopymbase.py:97: UserWarning: The program ../Bin/ does not exist or is not executable.
  warn(



 Models in simulation: ModelWebinar1d
#get package list
vtkGen.getPackageList()
Package list: ['DIS', 'BAS6', 'OC', 'NWT', 'UPW', 'DRN', 'RCH', 'EVT']
#generate model geometry as vtk and parameter array
vtkGen.generateGeometryArrays()
#generate parameter vtk
vtkGen.generateParamVtk() 
Parameter Vtk Generated
#not implemented yet!
#generate bc and obs vtk
#vtkGen.generateBcObsVtk()

Input data

You can download the input data on this link.

—————
TRANSCOM ISPFree Sigma HSE Email
Level 6 Domain Names are FREE – Register Now.

Related Posts

Hydrate

EGU2024

The mountain hydrology team will have full presence at EGU2024. Below you’ll find a list of the primary presentations by our team.

Full programme can be

Boost Inflight Internet- Business Hosting- Secure Email Account- Dropcatch Domain Names- Antisnoop Email- Free Secure Email- Cheap VOIP Calls- Free Hosting and Email- Aero Connectivity- Premium Domains for Sale- Transcom Telecom- Satphone Airtime- Mobile Plans- Free Domain Names- Organic Products- Aviation News
Transcom ISP - Transcom VOIP - Free Secure Email - Dropcatch Software - FastApn Inflight - Aero Connect - Premium Domains