0

我正在尝试学习 flopy,并尝试加载 MODFLOW-USG 测试用例之一。测试用例是一个带有嵌套网格和 GNC 包的 1 层模型(示例 01B)。我没有修改与 MODFLOW-USG 一起分发的测试用例文件,并且测试用例在 run.bat 文件中运行良好。

首先,我尝试按照示例使用flopy.modflow.mf 模块加载名称文件:

m = flopy.modflow.Modflow.load('flow.nam', version='mfusg')

但我得到了以下信息ValueError

File "C:\Users\Kent\Anaconda3\lib\site-packages\flopy\modflow\mf.py", line 758, in load
  ml.check(f='{}.chk'.format(ml.name), verbose=ml.verbose, level=0)

File "C:\Users\Kent\Anaconda3\lib\site-packages\flopy\mbase.py", line 1121, in check
  level=level - 1)

File "C:\Users\Kent\Anaconda3\lib\site-packages\flopy\modflow\mfbas.py", line 185, in check
  neighbors = get_neighbors(self.ibound.array)

File "C:\Users\Kent\Anaconda3\lib\site-packages\flopy\utils\check.py", line 590, in get_neighbors
  nk, ni, nj = a.shape

ValueError: not enough values to unpack (expected 3, got 1)

然后我尝试按照flopy.modflow.mfdisu 模块的示例加载 DISU 包:

m = flopy.modflow.Modflow(version='mfusg')
disu = flopy.modflow.ModflowDisU.load('flow.disu', m)

但这给了我以下信息TypeError

File "C:\Users\Kent\Anaconda3\lib\site-packages\flopy\modflow\mfdisu.py", line 622, in load
  fahl = Util2d.load(f, model, (n,), np.float32, 'fahl', ext_unit_dict)

File "C:\Users\Kent\Anaconda3\lib\site-packages\flopy\utils\util_array.py", line 2678, in load
  ext_unit = ext_unit_dict[cr_dict['nunit']]

TypeError: 'NoneType' object is not subscriptable

用软盘加载现有 MODFLOW-USG 模型的正确方法是什么?

4

0 回答 0