diff --git a/docs/dev/sdd.md b/docs/dev/sdd.md index 884fa897..cd93eb75 100644 --- a/docs/dev/sdd.md +++ b/docs/dev/sdd.md @@ -168,9 +168,11 @@ The sparse input format used by MODFLOW 6 is in tension with an object model whe The conversion layer (`flopy4.mf6.converter`) transforms between the product's `xarray`/`attrs`-based object model and plain Python data structures suitable for serialization. This layer is format-agnostic and handles structural transformations common across formats. +The generated classes are the only schema this layer reads. Codegen compiles the DFNs into each class's fields and their metadata, and no DFN is read at load or write: `flopy4.mf6.spec` finds a class's blocks (`file_blocks`) and how a block's rows find their fields (`block_keys`) from those fields. A test holds freshly generated classes to the DFNs they came from (`test/mf6/test_mf6_routing.py`), so what the converter needs from a DFN but a class doesn't carry is a codegen fix. + **Unstructuring (write time)**: `converter.egress.unstructure` converts components to a form suitable for serialization, handling transformations like: -- Grouping fields into blocks according to their `block` metadata from DFNs +- Grouping fields into blocks according to their `block` metadata - Converting child components to binding tables for parent component name files - Slicing time-varying arrays by stress period, returned in a period-indexed `dict` - Converting `Path` objects to tuples (``, `FILEIN`/`FILEOUT`, ``) diff --git a/docs/examples/circle.ipynb b/docs/examples/circle.ipynb index 08dd7724..e6eaa808 100644 --- a/docs/examples/circle.ipynb +++ b/docs/examples/circle.ipynb @@ -581,7 +581,7 @@ "sto = flopy4.mf6.gwf.Sto(\n", " ss=1.0e-5,\n", " sy=0.15,\n", - " stress_period_data={0: [(\"STEADY-STATE\",)]},\n", + " stress_period_data={0: \"steady-state\"},\n", " iconvert=0,\n", " dims=dims,\n", ")" diff --git a/docs/examples/circle.py b/docs/examples/circle.py index 824b887a..ca0c06e1 100644 --- a/docs/examples/circle.py +++ b/docs/examples/circle.py @@ -172,7 +172,7 @@ def plot_head_ugrid(head, cbc, workspace): sto = flopy4.mf6.gwf.Sto( ss=1.0e-5, sy=0.15, - stress_period_data={0: [("STEADY-STATE",)]}, + stress_period_data={0: "steady-state"}, iconvert=0, dims=dims, ) diff --git a/docs/examples/twri.ipynb b/docs/examples/twri.ipynb index 3f3f3ad4..514c7ef4 100644 --- a/docs/examples/twri.ipynb +++ b/docs/examples/twri.ipynb @@ -366,7 +366,7 @@ " storagecoefficient=False,\n", " ss=1.0e-5,\n", " sy=0.15,\n", - " stress_period_data={0: [(\"STEADY-STATE\",)]},\n", + " stress_period_data={0: \"steady-state\"},\n", " iconvert=0,\n", " dims=dims,\n", ")" diff --git a/docs/examples/twri.py b/docs/examples/twri.py index 7ac3295c..57d99cc5 100644 --- a/docs/examples/twri.py +++ b/docs/examples/twri.py @@ -129,7 +129,7 @@ def plot_head(head, workspace): storagecoefficient=False, ss=1.0e-5, sy=0.15, - stress_period_data={0: [("STEADY-STATE",)]}, + stress_period_data={0: "steady-state"}, iconvert=0, dims=dims, ) diff --git a/docs/migrating.md b/docs/migrating.md index 2c033b22..f297d256 100644 --- a/docs/migrating.md +++ b/docs/migrating.md @@ -31,14 +31,14 @@ you need to make anyway: flopy4's class names (`Sto`, not `flopy.mf6.ModflowGwfsto`), and its constructors taking the parent as a keyword (`parent=gwf`), not by position. -STO takes one entry per period, `STEADY-STATE` or `TRANSIENT`: +STO takes one word per period, `steady-state` or `transient`: ```python # flopy3 sto = flopy.mf6.ModflowGwfsto(gwf, steady_state={0: True}, transient={1: True}) # flopy4 -sto = Sto(parent=gwf, stress_period_data={0: [("STEADY-STATE",)], 1: [("TRANSIENT",)]}) +sto = Sto(parent=gwf, stress_period_data={0: "steady-state", 1: "transient"}) ``` OC takes each period's saves and prints in one list, each starting with diff --git a/flopy4/mf6/__init__.py b/flopy4/mf6/__init__.py index e713a8cf..ca12a7b3 100644 --- a/flopy4/mf6/__init__.py +++ b/flopy4/mf6/__init__.py @@ -176,7 +176,7 @@ def _write_mf6(component: Component, context=None, **kwargs) -> None: # settle the arrays' and lists' files before opening (and emptying) # the component's, which a strict write may refuse - data = annotate_arrays(unstructure(component), ctx) + data = annotate_arrays(unstructure(component), type(component), ctx) where = (component.root, component.filename, component._name_or_class()) data = write_external_arrays(data, *where, ctx) data = write_external_lists(data, *where, ctx) diff --git a/flopy4/mf6/chf/cdb.py b/flopy4/mf6/chf/cdb.py index caa6e92d..41e9b6cd 100644 --- a/flopy4/mf6/chf/cdb.py +++ b/flopy4/mf6/chf/cdb.py @@ -8,7 +8,7 @@ from flopy4.mf6._types import TimeSeriesRef, to_array from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, integer, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, child, double, integer, keyword, list_, string from flopy4.mf6.utl.obs import Obs @@ -19,6 +19,10 @@ class Cdb(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "cdb": (("cellid",), ("string",)), "to-mvr": (("cellid",), ("string",)), @@ -77,6 +81,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) @property diff --git a/flopy4/mf6/chf/chd.py b/flopy4/mf6/chf/chd.py index 1dc2ae8c..40ccc3d2 100644 --- a/flopy4/mf6/chf/chd.py +++ b/flopy4/mf6/chf/chd.py @@ -8,7 +8,7 @@ from flopy4.mf6._types import TimeSeriesRef, to_array from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, child, double, keyword, list_, string from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -20,6 +20,10 @@ class Chd(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "chd": (("cellid",), ("string",)), } @@ -85,6 +89,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) @property diff --git a/flopy4/mf6/chf/cxs.py b/flopy4/mf6/chf/cxs.py index 903b9f79..dfba27f3 100644 --- a/flopy4/mf6/chf/cxs.py +++ b/flopy4/mf6/chf/cxs.py @@ -44,11 +44,13 @@ class Crosssectiondata(Item): packagedata: Optional[list[Packagedata]] = list_( default=None, block="packagedata", + tagged=False, shape=("nsections",), ) crosssectiondata: Optional[list[Crosssectiondata]] = list_( default=None, block="crosssectiondata", + tagged=False, shape=("npoints",), ) diff --git a/flopy4/mf6/chf/disv1d.py b/flopy4/mf6/chf/disv1d.py index bef32e94..6a189372 100644 --- a/flopy4/mf6/chf/disv1d.py +++ b/flopy4/mf6/chf/disv1d.py @@ -118,11 +118,13 @@ class Cell1d(Item): vertices: Optional[list[Vertices]] = list_( default=None, block="vertices", + tagged=False, shape=("nvert",), ) cell1d: Optional[list[Cell1d]] = list_( default=None, block="cell1d", + tagged=False, shape=("nodes",), ) diff --git a/flopy4/mf6/chf/evp.py b/flopy4/mf6/chf/evp.py index 93e58831..d0a49893 100644 --- a/flopy4/mf6/chf/evp.py +++ b/flopy4/mf6/chf/evp.py @@ -8,7 +8,7 @@ from flopy4.mf6._types import TimeSeriesRef, to_array from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, child, double, keyword, list_, string from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -20,6 +20,10 @@ class Evp(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "evp": (("cellid",), ("string",)), } @@ -85,6 +89,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) @property diff --git a/flopy4/mf6/chf/flw.py b/flopy4/mf6/chf/flw.py index 886bab8b..6d65791b 100644 --- a/flopy4/mf6/chf/flw.py +++ b/flopy4/mf6/chf/flw.py @@ -8,7 +8,7 @@ from flopy4.mf6._types import TimeSeriesRef, to_array from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, child, double, keyword, list_, string from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -20,6 +20,10 @@ class Flw(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "flw": (("cellid",), ("string",)), "to-mvr": (("cellid",), ("string",)), @@ -86,6 +90,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) @property diff --git a/flopy4/mf6/chf/oc.py b/flopy4/mf6/chf/oc.py index 59b23ad4..e03e88a9 100644 --- a/flopy4/mf6/chf/oc.py +++ b/flopy4/mf6/chf/oc.py @@ -8,7 +8,7 @@ from flopy4.mf6.legacy import Legacy, oc_period_data from flopy4.mf6.package import Package from flopy4.mf6.record import Record -from flopy4.mf6.spec import array, file, integer, list_, record, string, union +from flopy4.mf6.spec import Header, array, file, integer, list_, record, string, union @attrs.define(kw_only=True, slots=False) @@ -16,6 +16,10 @@ class Oc(Package): dfn_name: ClassVar[str] = "chf-oc" ftype: ClassVar[str] = "OC6" + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + legacy_kwargs: ClassVar[dict[str, Legacy]] = { "saverecord": Legacy("stress_period_data", oc_period_data), "printrecord": Legacy("stress_period_data", oc_period_data), diff --git a/flopy4/mf6/chf/pcp.py b/flopy4/mf6/chf/pcp.py index ed1cbbc9..a3d95ea2 100644 --- a/flopy4/mf6/chf/pcp.py +++ b/flopy4/mf6/chf/pcp.py @@ -8,7 +8,7 @@ from flopy4.mf6._types import TimeSeriesRef, to_array from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, child, double, keyword, list_, string from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -20,6 +20,10 @@ class Pcp(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "pcp": (("cellid",), ("string",)), } @@ -85,6 +89,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) @property diff --git a/flopy4/mf6/chf/sto.py b/flopy4/mf6/chf/sto.py index f51036a9..88a8e58b 100644 --- a/flopy4/mf6/chf/sto.py +++ b/flopy4/mf6/chf/sto.py @@ -1,12 +1,11 @@ # autogenerated file, do not modify -from typing import ClassVar, Optional +from typing import ClassVar, Literal, Optional import attrs -from flopy4.mf6.item import Item from flopy4.mf6.legacy import Legacy, sto_period_data from flopy4.mf6.package import Package -from flopy4.mf6.spec import keyword, list_, string +from flopy4.mf6.spec import Header, keyword, string @attrs.define(kw_only=True, slots=False) @@ -14,15 +13,15 @@ class Sto(Package): dfn_name: ClassVar[str] = "chf-sto" ftype: ClassVar[str] = "STO6" + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + legacy_kwargs: ClassVar[dict[str, Legacy]] = { "steady_state": Legacy("stress_period_data", sto_period_data), "transient": Legacy("stress_period_data", sto_period_data), } - @attrs.define - class StressPeriodData(Item): - stress_period_data: str = string() - save_flows: bool = keyword( default=False, block="options", @@ -35,13 +34,10 @@ class StressPeriodData(Item): optional=True, longname="export array variables to layered ascii files.", ) - _stress_period_data: Optional[dict[int, list[StressPeriodData]]] = list_( - alias="stress_period_data", + stress_period_data: Optional[dict[int, Literal["steady-state", "transient"]]] = string( default=None, - repr=False, block="period", fill_forward=True, + valid=("steady-state", "transient"), + tagged=False, ) - - -StoStressPeriodData = Sto.StressPeriodData diff --git a/flopy4/mf6/chf/zdg.py b/flopy4/mf6/chf/zdg.py index 66d59fc9..4b92d993 100644 --- a/flopy4/mf6/chf/zdg.py +++ b/flopy4/mf6/chf/zdg.py @@ -8,7 +8,7 @@ from flopy4.mf6._types import TimeSeriesRef, to_array from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, integer, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, child, double, integer, keyword, list_, string from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -20,6 +20,10 @@ class Zdg(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "to-mvr": (("cellid",), ("string",)), "zdg": (("cellid",), ("string",)), @@ -83,6 +87,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) @property diff --git a/flopy4/mf6/codec/reader/transformer/basic.py b/flopy4/mf6/codec/reader/transformer/basic.py index 22740fab..978c27a8 100644 --- a/flopy4/mf6/codec/reader/transformer/basic.py +++ b/flopy4/mf6/codec/reader/transformer/basic.py @@ -46,13 +46,27 @@ def start(self, items: list[Any]) -> dict[str, Any]: return blocks def block(self, items: list[Any]) -> dict[str, Any]: - # BEGIN name line... END name + # BEGIN name line... END name. The grammar takes a BEGIN inside a + # block as a row and any name after END, so a block missing its END + # would swallow the next one; like MF6, stop on both. + begin, name, end_name = items[0], items[1], items[-1] + + def no_end(found: str) -> ValueError: + return ValueError( + f"{name.upper()} block, opened on line {begin.line}, has no END: " + f"found {found.upper()}" + ) + body: list[Any] = [] for item in items[2:-2]: if isinstance(item, _RecordRows): body.extend(item) else: + if isinstance(item, list) and item and item[0].upper() == "BEGIN": + raise no_end(" ".join(item)) body.append(item) + if end_name.split()[0].lower() != name.split()[0].lower(): + raise no_end(f"END {end_name}") if len(body) == 1 and isinstance(body[0], NumberRows): return {items[1]: body[0]} if any(isinstance(item, NumberRows) for item in body): diff --git a/flopy4/mf6/component.py b/flopy4/mf6/component.py index b87a0152..dbf0a7cf 100644 --- a/flopy4/mf6/component.py +++ b/flopy4/mf6/component.py @@ -13,7 +13,7 @@ from flopy4.mf6.constants import MF6 from flopy4.mf6.external import in_write_session, write_session from flopy4.mf6.legacy import Legacy, LegacyKwargs -from flopy4.mf6.spec import fields_dict +from flopy4.mf6.spec import Header, fields_dict from flopy4.mf6.write_context import WriteContext from flopy4.spec import is_reference, reference_names, referenced, resolve, retarget from flopy4.uio import IO, Loader, Writer @@ -254,6 +254,9 @@ class Component(DimensionResolverMixin, ABC, MutableMapping, metaclass=LegacyKwa """The token naming the component's file type in name files (e.g. 'GWF6', 'CHD6', 'GWF6-GWT6'), from its DFN. Array-based variants share their base's ('Chdg' is 'CHD6'). Empty for the simulation.""" + headers: ClassVar[dict[str, Header]] = {} + """The header of each of the component's repeating blocks, by block + name, set by codegen from the DFN (see `Header`).""" _load = IO(Loader) # type: ignore _write = IO(Writer) # type: ignore diff --git a/flopy4/mf6/converter/egress/unstructure.py b/flopy4/mf6/converter/egress/unstructure.py index b0e519ba..0db03e98 100644 --- a/flopy4/mf6/converter/egress/unstructure.py +++ b/flopy4/mf6/converter/egress/unstructure.py @@ -1,6 +1,5 @@ -from collections.abc import Iterable, Mapping -from datetime import datetime -from functools import cache, partial +from collections.abc import Mapping +from functools import cached_property, partial from pathlib import Path from typing import Any @@ -10,25 +9,26 @@ from modflow_devtools.dfns import dim_value from flopy4._imports import isinstance_of -from flopy4.attrs_xarray import child_field_candidates from flopy4.mf6._types import TimeArraySeriesRef from flopy4.mf6.block import block_list_type from flopy4.mf6.component import Component, WorkspaceComponent from flopy4.mf6.constants import FILL_DNODATA from flopy4.mf6.converter.binding import write_row +from flopy4.mf6.converter.ingress.structure import _init_key, _per_header from flopy4.mf6.dims_provider_methods import DimsProviderMethods -from flopy4.mf6.item import ( - Item, - conditional_fields, - dim_lookup, - item_list_type, - sized_by, -) +from flopy4.mf6.item import Item, conditional_fields, dim_lookup, item_list_type, sized_by from flopy4.mf6.item_table import ItemTable, Rows from flopy4.mf6.package import Package from flopy4.mf6.period_arrays import is_cleared, is_grid_package from flopy4.mf6.record import Record, record_type -from flopy4.mf6.spec import FileDirection, block_sort_key, blocks_dict, to_field_type +from flopy4.mf6.spec import ( + FileDirection, + binding_fields, + block_keys, + field_key, + file_blocks, + is_tagged, +) from flopy4.mf6.write_context import WriteContext from flopy4.spec import is_array @@ -54,51 +54,6 @@ def _child_path(child: Component) -> Path: return Path(path.name) if path.is_absolute() else path -def _put_child_file_records(block: dict, field: attrs.Attribute, value: Any) -> None: - """File records naming children: NCF6 FILEIN .""" - children = value if isinstance(value, list) else [value] - rows = [_path_to_tuple(field, _child_path(c)) for c in children if c is not None] - if rows and isinstance(value, list): - block[field.name] = rows - elif rows: - block[rows[0][0].lower()] = rows[0] - - -def _make_binding_blocks(value: Component) -> dict[str, dict[str, list[tuple[str, ...]]]]: - if not isinstance(value, WorkspaceComponent): - return {} - - blocks = {} # type: ignore - - for f in attrs.fields(type(value)): # type: ignore[arg-type] - # a child() field; a record option is a field like any other - if not f.metadata.get("child") or child_field_candidates(f) is None: - continue - child_name = f.name - if (child := getattr(value, child_name, None)) is None: - continue - block_name = f.metadata.get("block") - if block_name is None: - continue - if block_name not in blocks: - blocks[block_name] = {} - if f.metadata.get("_keyword"): - _put_child_file_records(blocks[block_name], f, child) - continue - columns = f.metadata["row"] - match child: - case Component(): - blocks[block_name][child_name] = [write_row(child, columns)] - case Iterable(): - rows = [write_row(c, columns) for c in child if c is not None] - if rows: - blocks[block_name][child_name] = rows - case _: - raise ValueError(f"Unexpected child type: {type(child)}") - - return blocks - - def _grid_dims(value: Package) -> tuple[int, tuple[int, ...]]: """(nlay, layer shape) of the package's grid: a layer is (nrow, ncol) on a structured grid, else (ncpl,). Empty if the grid isn't known. A grid @@ -246,198 +201,24 @@ def _normalize_kper(kper: Any) -> int | None: return None -def _unstructure_package(value: Package) -> dict[str, Any]: - """Unstructure a package into a dict.""" - cls = type(value) - blocks: dict[str, dict[str, Any]] = {} - write_if_empty_set: set[str] = set() - spd_period: dict[int, Rows] = {} - readarray_period: dict[int, dict[str, Any]] = {} - # per period, the (non-aux) array fields given, and those all DNODATA - stress_period: dict[int, set[str]] = {} - nodata_period: dict[int, set[str]] = {} - # resolved once, if an array's written - grid_dims = cache(lambda: _grid_dims(value)) - ncelldim = _ncelldim(value) - grid = is_grid_package(cls) - fill_forward_block: str | None = None - - for f in attrs.fields(cls): # type: ignore[arg-type] - meta = f.metadata - block_name = meta.get("block") - if not block_name: - continue - - if meta.get("write_if_empty"): - write_if_empty_set.add(block_name) - blocks.setdefault(block_name, {}) - - attr_name = f.alias if (f.alias and f.name.startswith("_")) else f.name - field_value = getattr(value, attr_name, None) - if field_value is None: - continue - - dfn_type = to_field_type(f.type) - - # fill-forward block - if meta.get("fill_forward"): - fill_forward_block = block_name - # dynamically named arrays (RCHA's aux): {kper: {name: array}}, each - # written under its name - if meta.get("fk"): - for kper, arrays in field_value.items(): - for name, arr in arrays.items(): - readarray_period.setdefault(kper, {})[name] = _period_dataarray( - name, arr, meta, *grid_dims() - ) - continue - # arrays: {kper: array} - if item_list_type(f.type) is None: - for kper, arr in field_value.items(): - # a cleared grid period's array is None, filled below - readarray_period.setdefault(kper, {})[f.name] = ( - None if arr is None else _period_dataarray(f.name, arr, meta, *grid_dims()) - ) - if grid and is_cleared(arr): - nodata_period.setdefault(kper, set()).add(f.name) - stress_period.setdefault(kper, set()).add(f.name) - continue - # list: dict[int, list[Item]] - if not isinstance(field_value, dict): - continue - list_kwargs = _list_kwargs(value, attr_name, f) - for kper, row_list in field_value.items(): - kper_int = _normalize_kper(kper) - if kper_int is None: - continue - rows = spd_period.setdefault(kper_int, Rows(ncelldim, **list_kwargs)) - if isinstance(row_list, (list, ItemTable)): - rows.append(row_list) - continue - - # blocks repeating under a record header (OBS's CONTINUOUS), one per - # header: list[Block] - if (block_cls := block_list_type(f.type)) is not None: - _, list_name, _ = block_cls.parts() - for block in field_value: - key = " ".join([block_name, *map(str, block.header_tokens())]) - blocks[key] = {list_name: _rows(getattr(block, list_name), ncelldim)} - continue - - if isinstance(field_value, dict): - # arrays keyed by time (a TAS's), a layer each - array_key = f.name if meta.get("tagged") else "" - for tval, arr in field_value.items(): - arr = arr if hasattr(arr, "shape") or isinstance(arr, str) else np.asarray(arr) - blocks[f"{block_name} {tval}"] = {array_key: _grid_shaped(arr, meta, *grid_dims())} - continue - - # non-fill-forward block - if block_name not in blocks: - blocks[block_name] = {} - - if dfn_type == "keyword": - if field_value: - blocks[block_name][f.name] = field_value - - elif isinstance(field_value, list) and field_value and isinstance(field_value[0], Path): - # A list of file records (DFN tagged list): one line each. - blocks[block_name][f.name] = [_path_to_tuple(f, v) for v in field_value] - - elif meta.get("direction") and isinstance(field_value, Path): - t = _path_to_tuple(f, field_value) - blocks[block_name][t[0].lower()] = t - - elif meta.get("child") and meta.get("_keyword"): - _put_child_file_records(blocks[block_name], f, field_value) - - elif ( - isinstance(field_value, (list, ItemTable)) - and field_value - and isinstance(field_value[0], Item) - ): - blocks[block_name][f.name] = _rows( - field_value, ncelldim, **_list_kwargs(value, attr_name, f) - ) - - elif isinstance(field_value, list) and field_value and isinstance(field_value[0], tuple): - blocks[block_name][f.name] = field_value - - elif is_array(f) and meta.get("shape") and not isinstance(field_value, bool): - # a grid array; an inline one has no shape (AUXILIARY's names) - if meta.get("index"): - field_value = _to_file_index(field_value) - # a grid package's arrays are shaped like its grid; others' (NPF's - # K) stay as given, non-layered, which MF6 reads in one go - dims = grid_dims() if isinstance(value, DimsProviderMethods) else (1, ()) - blocks[block_name][f.name] = _mark_netcdf(_grid_shaped(field_value, meta, *dims), meta) - - elif isinstance(field_value, np.ndarray) and field_value.dtype.kind == "U": - # An inline string array (AUXILIARY's names): one line. - if field_value.size: - blocks[block_name][f.name] = (f.name.upper(), *map(str, field_value)) - - elif isinstance(field_value, Record): - blocks[block_name][f.name] = field_value.to_tokens() - - elif (rec := record_type(f.type)) is not None: - raise _not_a_record(value, f.name, rec, field_value) - - elif dfn_type in ("integer", "double", "double precision"): - blocks[block_name][f.name] = field_value - - elif dfn_type == "string" and field_value: - blocks[block_name][f.name] = field_value - - # `maxbound` is a computed property on some classes, not a real field - if isinstance(getattr(cls, "maxbound", None), property): - maxbound = value.maxbound # type: ignore[attr-defined] - if maxbound: - blocks.setdefault("dimensions", {})["maxbound"] = maxbound - - # sort filled blocks by label - if fill_forward_block is not None: - for kper in sorted(spd_period.keys()): - key = f"{fill_forward_block} {kper + 1}" - blocks[key] = {fill_forward_block: spd_period[kper]} - - # One block per period any array is given in. A grid package's - # period whose stress arrays are all DNODATA clears every boundary: - # an empty block. - for kper in sorted(readarray_period.keys()): - key = f"{fill_forward_block} {kper + 1}" - if grid and stress_period.get(kper) and nodata_period.get(kper) == stress_period[kper]: - blocks[key] = {} - write_if_empty_set.add(key) - else: - arrays = readarray_period[kper] - like = next(a for a in arrays.values() if a is not None) - blocks[key] = { - n: xr.full_like(like, FILL_DNODATA, dtype=np.float64) if a is None else a - for n, a in arrays.items() - } - - return { - name: block - for name, block in sorted(blocks.items(), key=block_sort_key) - if block or name in write_if_empty_set - } - - -def annotate_arrays(data: dict[str, Any], context: WriteContext) -> dict[str, Any]: +def annotate_arrays( + data: dict[str, Any], cls: type[Component], context: WriteContext +) -> dict[str, Any]: """Copy each array's settings from `context.arrays` (see `ArrayKey`) onto the DataArray `data` holds for it, as attrs the writer reads: `iprn`, and `layer_iprn` for layers of a layered array whose IPRN differs from the whole array's; `path`, `format`, `hash` and `layered`, and `layer_path`, `layer_format` and `layer_hash` for layers given their - own (see `write_external_arrays` and `array_how`). A period block's - arrays are keyed by period.""" + own (see `write_external_arrays` and `array_how`). A block whose + header is an index (a period's IPER, see `cls.headers`) has its + arrays keyed by it, 0-based.""" if not context.arrays: return data out: dict[str, Any] = {} for block_name, block in data.items(): name, _, header = block_name.partition(" ") - kper = int(header) - 1 if name == "period" and header.isdigit() else None + kind = cls.headers.get(name) + kper = int(header) - 1 if kind is not None and kind.index and header.isdigit() else None if not isinstance(block, dict): out[block_name] = block continue @@ -481,74 +262,226 @@ def _not_a_record(component: Component, name: str, rec: type[Record], value: Any def unstructure_component(value: Component) -> dict[str, Any]: - # TODO unify _unstructure_package/_unstructure_component into one path - if isinstance(value, Package): - return _unstructure_package(value) - return _unstructure_component(value) - - -def _unstructure_component(value: Component) -> dict[str, Any]: - """Unstructure an internal-node component (Gwf, Simulation, etc.) with - attrs-typed child fields, including its child binding blocks.""" - blockspec = blocks_dict(type(value)) - blocks: dict[str, dict[str, Any]] = {} - fields_by_name = {f.name: f for f in attrs.fields(type(value))} # type: ignore[arg-type] - - # create child component binding blocks - blocks.update(_make_binding_blocks(value)) - - for block_name, block in blockspec.items(): - if block_name not in blocks: - blocks[block_name] = {} - - for field_name in block.keys(): - # Skip child components already processed as bindings - field = fields_by_name.get(field_name) - if ( - isinstance(value, WorkspaceComponent) - and field is not None - and field.metadata.get("child") - and child_field_candidates(field) is not None - and field.metadata.get("block") == block_name + """A component as the writer takes it, ``{block: {field: value}}`` + (see `_Unstructure`).""" + return _Unstructure(value).blocks() + + +class _Unstructure: + """One component's blocks for the writer, the inverse of the loader's + `_Load`: its class's blocks, in file order (see `file_blocks`), each + field keyed by its name in the file (see `field_key`), from its + attribute or from a property computing it (a list package's MAXBOUND). + A repeating block is written once per header (see `occurrences`), and the rows + naming children (a model's packages, the simulation's models and + solutions) are made from them (see `bindings`). A block with nothing + to write is left out, unless codegen marked it `write_if_empty` or + it's a name file's.""" + + def __init__(self, value: Component) -> None: + self.value = value + self.cls = type(value) + self._fields = attrs.fields_dict(self.cls) # type: ignore[arg-type] + self.grid = is_grid_package(self.cls) + # blocks whose rows name children + self.binding_blocks = binding_fields(self.cls) + + @cached_property + def ncelldim(self) -> int | None: + return _ncelldim(self.value) if isinstance(self.value, Package) else None + + @cached_property + def grid_dims(self) -> tuple[int, tuple[int, ...]]: + return _grid_dims(self.value) # type: ignore[arg-type] + + def blocks(self) -> dict[str, dict[str, Any]]: + out: dict[str, dict[str, Any]] = {} + keep: set[str] = set() + for name in file_blocks(self.cls): + if isinstance(self.value, WorkspaceComponent) or any( + f.metadata.get("write_if_empty") + for f in self._fields.values() + if f.metadata.get("block") == name ): - continue + keep.add(name) + if name not in self.cls.headers: + out[name] = self.body(name) + else: + for header, (body, empty) in self.occurrences(name).items(): + out[f"{name} {header}"] = body + if empty: + keep.add(f"{name} {header}") + return {name: body for name, body in out.items() if body or name in keep} + + def entries(self, name: str) -> "dict[str, attrs.Attribute | None]": + """The block `name`'s fields, in file order, by their keys for the + writer: a computed field first, with no attribute; a binding block's + children as one entry, its rows, keyed and placed where the first + of them is, likewise with no attribute.""" + out: "dict[str, attrs.Attribute | None]" = dict.fromkeys( + block_keys(self.cls, name).computed + ) + for a in file_blocks(self.cls)[name]: + if a.metadata.get("row"): + out[name] = None + else: + out[field_key(a)] = a + return out + + def body(self, name: str) -> dict[str, Any]: + """A block that doesn't repeat, by field.""" + values = {key: self.value_of(name, key, a) for key, a in self.entries(name).items()} + return {k: v for k, v in values.items() if v is not None} + + def value_of(self, name: str, key: str, a: "attrs.Attribute | None") -> Any: + """The field's value as the writer takes it, or None to leave it + out. With no attribute, it's a binding block's rows or a computed + field; a MAXBOUND of 0 (no rows) isn't written.""" + if a is None: + return self.bindings(name) if key == name else getattr(self.value, key) or None + value = getattr(self.value, _init_key(a), None) + return None if value is None else self.field(key, a, value) + + def field(self, key: str, a: attrs.Attribute, value: Any) -> Any: + """The field `a`'s value as the writer takes it, by its type, or + None to leave it out.""" + meta = a.metadata + if meta.get("child"): + # a child's file record: OBS6 FILEIN + if isinstance(value, list): + return [_path_to_tuple(a, _child_path(c)) for c in value if c is not None] or None + return _path_to_tuple(a, _child_path(value)) + match meta.get("type"): + case "keyword": + return value or None + case "integer" | "double": + return value + case "string": + return value or None + case "file" if isinstance(value, list): + # a tagged list of file records: one line each + return [_path_to_tuple(a, v) for v in value] or None + case "file": + return _path_to_tuple(a, value) + case "record": + if not isinstance(value, Record): + raise _not_a_record(self.value, a.name, record_type(a.type) or Record, value) + return value.to_tokens() + case "array" if meta.get("shape"): + # a grid array; a grid package's are shaped like its grid, + # others' (NPF's K) stay as given, non-layered, which MF6 + # reads in one go + if meta.get("index"): + value = _to_file_index(value) + dims = self.grid_dims if isinstance(self.value, DimsProviderMethods) else (1, ()) + return _mark_netcdf(_grid_shaped(value, meta, *dims), meta) + case "array": + # inline (AUXILIARY's names): one line + return (key.upper(), *map(str, value)) if len(value) else None + case "list" if not value: + return None + case "list" if isinstance(value[0], tuple): + return value + case "list": + return _rows(value, self.ncelldim, **self.list_kwargs(a)) + return None - raw_value = getattr(value, field_name, None) - if raw_value is None: + def bindings(self, name: str) -> list[tuple[str, ...]] | None: + """The rows naming the children of the block `name` (``GWF6 + ``), in field order: the inverse of + `_resolve_bindings`.""" + rows = [] + for f, *_ in self.binding_blocks.get(name, ()): + child = getattr(self.value, f.name, None) + children = child if isinstance(child, list) else [child] + rows += [write_row(c, f.metadata["row"]) for c in children if c is not None] + return rows or None + + def list_kwargs(self, a: attrs.Attribute) -> dict[str, Any]: + """A list field's `Rows` arguments, for writing it to a file.""" + return _list_kwargs(self.value, _init_key(a), a) # type: ignore[arg-type] + + def occurrences(self, name: str) -> dict[str, tuple[dict[str, Any], bool]]: + """A repeating block's occurrences by header as written (a period's + 1-based number), each its fields and whether it's written even if + empty (a grid package's period clearing every boundary). A field + holding one value, not one per header (the simulation's MXITER), + is the first occurrence's (``SOLUTIONGROUP 1``). A period's + cleared grid array (None) is written as DNODATA.""" + header = self.cls.headers[name] + numbered = header.kind != "record" + found: dict[Any, dict[str, Any]] = {} + # per period, the (non-aux) arrays given, and those all DNODATA + given: dict[Any, set[str]] = {} + cleared: dict[Any, set[str]] = {} + for key, a in self.entries(name).items(): + if a is None or not _per_header(a): + if (value := self.value_of(name, key, a)) is not None: + found.setdefault(1, {})[key] = value continue - # a private field's file name is its alias (Gwf's _list: LIST), a - # renamed keyword's is its name without the underscore (continue_) - key = field.alias if field is not None and field_name.startswith("_") else field_name - key = key.removesuffix("_") - if isinstance(raw_value, Record): - blocks[block_name][key] = raw_value.to_tokens() + if (value := getattr(self.value, _init_key(a), None)) is None: continue - if field is not None and (rec := record_type(field.type)) is not None: - raise _not_a_record(value, field_name, rec, raw_value) - - # Dispatch on field value type - match field_value := raw_value: - case None: - continue - case bool(): - if field_value: - blocks[block_name][key] = field_value - case Path(): - assert field is not None # field_name comes from blocks_dict(type(value)) - t = _path_to_tuple(field, field_value) - blocks[block_name][t[0]] = t - case datetime(): - blocks[block_name][key] = field_value.isoformat() - case _: - blocks[block_name][key] = field_value - - blocks = dict(sorted(blocks.items(), key=block_sort_key)) - - # total temporary hack! manually set solutiongroup 1. - # TODO still need to support multiple.. - if "solutiongroup" in blocks: - sg = blocks["solutiongroup"] - blocks["solutiongroup 1"] = sg - del blocks["solutiongroup"] - - return {name: block for name, block in blocks.items()} + meta = a.metadata + if (blocks := block_list_type(a.type)) is not None: + # OBS's CONTINUOUS FILEOUT : list[Block] + _, list_name, _ = blocks.parts() + for b in value: + header_tokens = " ".join(map(str, b.header_tokens())) + found.setdefault(header_tokens, {})[key] = _rows( + getattr(b, list_name), self.ncelldim + ) + elif meta.get("fk"): + # dynamically named arrays (RCHA's aux): {kper: {name: array}}, + # each written under its name + for kper, arrays in value.items(): + for aux, arr in arrays.items(): + found.setdefault(kper, {})[aux] = _period_dataarray( + aux, arr, meta, *self.grid_dims + ) + elif is_array(a) and meta.get("fill_forward"): + for kper, arr in value.items(): + found.setdefault(kper, {})[key] = ( + None if arr is None else _period_dataarray(key, arr, meta, *self.grid_dims) + ) + if self.grid and is_cleared(arr): + cleared.setdefault(kper, set()).add(key) + given.setdefault(kper, set()).add(key) + elif is_array(a): + # TAS times: {time: array}, a layer each + tag = key if is_tagged(a) else "" + for time, arr in value.items(): + arr = arr if hasattr(arr, "shape") or isinstance(arr, str) else np.asarray(arr) + found.setdefault(time, {})[tag] = _grid_shaped(arr, meta, *self.grid_dims) + elif meta.get("type") == "string": + # a word per period (STO's steady-state or transient), untagged, + # written uppercase as keywords are + for kper, word in value.items(): + found.setdefault(kper, {})[""] = word.upper() + else: + # a list per period: {kper: list[Item]} + list_kwargs = self.list_kwargs(a) + for kper, row_list in value.items(): + if (kper := _normalize_kper(kper)) is None: + continue + rows = found.setdefault(kper, {}).setdefault( + key, Rows(self.ncelldim, **list_kwargs) + ) + if isinstance(row_list, (list, ItemTable)): + rows.append(row_list) + + out: dict[str, tuple[dict[str, Any], bool]] = {} + for h in sorted(found) if numbered else found: + body = found[h] + label = h + 1 if header.index else h + if self.grid and given.get(h) and cleared.get(h) == given[h]: + # every stress array DNODATA clears every boundary: an empty block + out[str(label)] = ({}, True) + continue + if any(v is None for v in body.values()): + like = next(v for v in body.values() if v is not None) + body = { + k: xr.full_like(like, FILL_DNODATA, dtype=np.float64) if v is None else v + for k, v in body.items() + } + out[str(label)] = (body, False) + return out diff --git a/flopy4/mf6/converter/ingress/structure.py b/flopy4/mf6/converter/ingress/structure.py index d16183a0..6c82ea77 100644 --- a/flopy4/mf6/converter/ingress/structure.py +++ b/flopy4/mf6/converter/ingress/structure.py @@ -1,6 +1,5 @@ import warnings from abc import ABC -from collections import Counter from collections.abc import Callable, Mapping from pathlib import Path from typing import Any, cast, get_args, get_origin @@ -20,7 +19,7 @@ parts, without_comments, ) -from flopy4.mf6.component import Component, get_ftype +from flopy4.mf6.component import Component, get_ftypes from flopy4.mf6.converter.binding import read_row from flopy4.mf6.external import read_array_file, read_binary_list_file, read_list_file from flopy4.mf6.item import ( @@ -40,7 +39,14 @@ from flopy4.mf6.package import Package from flopy4.mf6.period_arrays import is_grid_package from flopy4.mf6.record import Record -from flopy4.mf6.spec import repeating_array_key_type, to_field_type +from flopy4.mf6.spec import ( + BlockKeys, + binding_fields, + block_keys, + file_blocks, + following_tags, + to_field_type, +) from flopy4.mf6.write_context import ArrayIO, ListIO, WriteContext, array_hash, list_hash from flopy4.spec import is_array, referenced from flopy4.utils import fortran_float, from_text, unwrap_optional @@ -59,6 +65,33 @@ def _inner_class_type(field_type) -> type[Record] | None: return None +def _tagged_value(f: Any, row: list) -> Any: + """The value of the tagged field `f` from its row, which begins with + its key: a record's, from all its tokens; a keyword's, True; an + inline array's (AUXILIARY's names), the rest of the row; a scalar's, + the token after the key. MF6 ignores anything after what the field + takes (often an inline comment, or a second value like IMS's + `UNDER_RELAXATION NONE DBD`).""" + # A Record-typed field must go through from_tokens(), even when the + # matched token is the field's own name rather than the record's + # trigger keyword. + if (inner_cls := _inner_class_type(f.type)) is not None: + return inner_cls.from_tokens(row) + t = unwrap_optional(f.type) + if t is bool: + return True + if get_origin(t) in (list, np.ndarray, npt.NDArray): + # even with one element; numpy >= 2.5's NDArray[X] has origin + # NDArray, not ndarray + args = get_args(t) + elem = args[-1] if get_origin(t) is not list else (args[0] if args else Any) + if get_origin(elem) is np.dtype: + elem = get_args(elem)[0] if get_args(elem) else Any + elem = {np.int64: int, np.float64: float, np.str_: str}.get(elem, elem) + return [from_text(v, elem) for v in row[1:]] + return from_text(row[1], t) + + def _parse_rows( rows: list, item_cls: "type[Item] | tuple[type[Item], ...]", @@ -119,7 +152,6 @@ def _read_open_close_values(vrow: list, context: LoadContext, dtype, length: int if not tokens: raise ValueError("OPEN/CLOSE control record missing a filename") path = context.resolve(_strip_quotes(tokens[0])) - binary = any(t.upper() in ("BINARY", "(BINARY)") for t in tokens[1:]) return read_array_file(path, dtype, length, binary=binary) @@ -222,6 +254,34 @@ def _leading_word(part) -> str: return str(part[0]).upper() +def _is_record(part) -> bool: + """Whether the part continues an array's name row: a control record, + or its values (a row of numbers).""" + if isinstance(part, NumberRows): + return True + return _leading_word(part) in _CONTROL_KINDS or bool(_numeric_prefix(part[:1])) + + +def _groups(parts: list) -> list[list]: + """A block's parts (see `parts`), each row with the records after it + (see `_is_record`): an array's name row with its control records and + values. Records before any row are a group of their own.""" + groups: list[list] = [] + for part in parts: + if not part: + continue + if groups and _is_record(part): + groups[-1].append(part) + else: + groups.append([part]) + return groups + + +def _rows_of(parts: list) -> list: + """Parts as rows, a `NumberRows`' each.""" + return [row for part in parts for row in (part if isinstance(part, NumberRows) else [part])] + + def _numeric_prefix(row: list) -> list: """Tokens from the start of `row` up to (not including) the first non-numeric one. Real INTERNAL/bare-data-row array data is purely @@ -243,25 +303,24 @@ def _numeric_prefix(row: list) -> list: return out -def _apply_factor(values: np.ndarray, vrow: list) -> np.ndarray: - """Scale `values` by the INTERNAL/OPEN-CLOSE control record's - ``FACTOR `` option, if `vrow` has one. MF6 reads an integer - array's FACTOR as an integer, so it's truncated to one here too.""" +def _factor(vrow: list, dtype) -> "int | float | None": + """The INTERNAL/OPEN-CLOSE control record's ``FACTOR `` option, if + `vrow` has one. MF6 reads an integer array's FACTOR as an integer, so + it's truncated to one here too.""" tokens = [str(t) for t in vrow[1:]] for j, tok in enumerate(tokens): if tok.upper() == "FACTOR" and j + 1 < len(tokens): factor = fortran_float(tokens[j + 1]) - if values.dtype == np.int64: - return values * int(factor) - return values * factor - return values + return int(factor) if dtype == np.int64 else factor + return None def _control_io(vrow: list, values: np.ndarray) -> ArrayIO: """How a control record wrote its array, to write it back the same way: its kind, as an `ArrayFormat`, and ``IPRN ``; an OPEN/CLOSE record's file, as written (relative to the simulation directory), and - the hash of the `values` read from it.""" + the hash of the `values` read from it, scaled by its FACTOR. The + FACTOR itself isn't kept: see `ArrayIO`.""" kind = _leading_word(vrow) if kind == "CONSTANT": return ArrayIO(format="constant") @@ -311,49 +370,52 @@ def _record_array_io( def _read_control_record( rows: list, i: int, context: LoadContext, dtype, length: int, name: str = "" -) -> "tuple[np.ndarray, int]": +) -> "tuple[np.ndarray, ArrayIO, int]": """Read one CONSTANT/INTERNAL/OPEN-CLOSE array control record starting - at ``rows[i]`` (a block's `parts`), shared by array blocks (`_parse_array_block`) and - READARRAY period (`_parse_readarray_period_block`) array ingress. - - Always returns a full ``length``-element ``ndarray`` (CONSTANT - broadcasts here rather than leaving that to the caller) plus the next - row index to resume from. INTERNAL's (and a bare, keyword-less data - row's) values commonly wrap across multiple physical lines for a large - array -- each is one row here -- so both keep consuming rows until - ``length`` values are collected, rather than assuming exactly one row. + at ``rows[i]`` (a block's `parts`), for `_read_array`. + + Returns a full ``length``-element ``ndarray`` (CONSTANT broadcasts + here rather than leaving that to the caller), scaled by its FACTOR; + how the record wrote it (see `_control_io`); and the next row index to + resume from. INTERNAL's (and a bare, keyword-less data row's) values + commonly wrap across multiple physical lines for a large array -- each + is one row here -- so both keep consuming rows until ``length`` values + are collected, rather than assuming exactly one row. Too few raises; ``name`` prefixes errors. """ vrow = rows[i] kind = _leading_word(vrow) if kind == "CONSTANT": v = from_text(vrow[1], int if dtype == np.int64 else float) - return np.full(length, v, dtype=dtype), i + 1 + return np.full(length, v, dtype=dtype), ArrayIO(format="constant"), i + 1 + factor = _factor(vrow, dtype) if kind == "OPEN/CLOSE": # read only the values the array needs; a file may hold more - return _apply_factor(_read_open_close_values(vrow, context, dtype, length), vrow), i + 1 - j = i + 1 if kind == "INTERNAL" else i - chunks: list[np.ndarray] = [] - count = 0 - while count < length and j < len(rows): - part = rows[j] - if isinstance(part, NumberRows): - text = without_comments(part.raw_text) - elif prefix := _numeric_prefix(part): - text = " ".join(map(str, prefix)) - else: - break - chunk = array_values(text, dtype, source=name) - chunks.append(chunk) - count += len(chunk) - j += 1 - if count < length: - source = f"{name}: " if name else "" - raise ValueError(f"{source}expected {length} values, got {count}") - array = np.concatenate(chunks)[:length] if chunks else np.array([], dtype=dtype) - if kind == "INTERNAL": - array = _apply_factor(array, vrow) - return array, j + array = _read_open_close_values(vrow, context, dtype, length) + j = i + 1 + else: + j = i + 1 if kind == "INTERNAL" else i + chunks: list[np.ndarray] = [] + count = 0 + while count < length and j < len(rows): + part = rows[j] + if isinstance(part, NumberRows): + text = without_comments(part.raw_text) + elif prefix := _numeric_prefix(part): + text = " ".join(map(str, prefix)) + else: + break + chunk = array_values(text, dtype, source=name) + chunks.append(chunk) + count += len(chunk) + j += 1 + if count < length: + source = f"{name}: " if name else "" + raise ValueError(f"{source}expected {length} values, got {count}") + array = np.concatenate(chunks)[:length] if chunks else np.array([], dtype=dtype) + if factor is not None: + array = array * factor + return array, _control_io(vrow, array), j def _from_file_index(value: np.ndarray) -> np.ndarray: @@ -362,111 +424,96 @@ def _from_file_index(value: np.ndarray) -> np.ndarray: return np.abs(value) - 1 -def _griddata_flat_length(f, dims: dict, default: int) -> int: - """Target length for a non-layered griddata field's flat array -- - e.g. DIS's `delr`/`delc` are `(ncol,)`/`(nrow,)`, not `(nodes,)`. Falls - back to `default` (the grid's total node count) when the field's - declared shape dimension isn't resolvable from `dims`. - """ - shape_meta = f.metadata.get("shape") - if shape_meta: - dim_name = shape_meta[-1] if isinstance(shape_meta, (tuple, list)) else shape_meta - if dim_name in dims: - return dims[dim_name] - return default +@attrs.frozen +class _Grid: + """The grid sizes an array's shape resolves against: the dims, with + ``nodes`` and ``ncpl`` filled in from each other and ``nlay``.""" + + dims: dict + nlay: int + ncpl: int + + @classmethod + def of(cls, dims: Mapping[str, int]) -> "_Grid | None": + """The grid of `dims`, or None if they give no cells.""" + nlay = dims.get("nlay", 1) + # a component with cells but no layers of its own has only ncpl (NCF) + nodes = dims.get("nodes") or nlay * dims.get("ncpl", 0) + if not nodes: + return None + ncpl = nodes // nlay if nlay else nodes + return cls({"nodes": nodes, "ncpl": ncpl, **dims}, nlay or 1, ncpl) + + def size(self, f: Any) -> int: + """How many values the array field `f` holds: its shape (one + dimension, e.g. DIS's `delr` is ``(ncol,)``, `botm` ``(nodes,)``) + resolved against the dims, else every node. An unknown field's + array is a layer's (a G/A package's).""" + if f is None: + return self.ncpl + shape = f.metadata.get("shape") or () + name = shape[-1] if isinstance(shape, (tuple, list)) and shape else shape + return self.dims.get(name) or self.dims["nodes"] -def _parse_array_block( +def _read_array( rows: list, - fields_by_name: dict, - dims: dict, + i: int, + f: Any, + grid: _Grid, context: LoadContext, - arrays: "dict | None" = None, -) -> dict: - """Parse an array block's (GRIDDATA, DISU's CONNECTIONDATA) token rows - into {field_name: np.ndarray}. - - Token rows alternate: [field_name, ?LAYERED] then one control record - per layer (LAYERED) or a single one otherwise -- CONSTANT/INTERNAL/ - OPEN-CLOSE, per `_read_control_record`. How each array was written - goes in `arrays`, per `_record_array_io`. - """ - result: dict = {} - nlay = dims.get("nlay", 1) - # a component with cells but no layers of its own has only ncpl (NCF) - nodes = dims.get("nodes") or nlay * dims.get("ncpl", 0) - if not nodes: - return result - ncpl = nodes // nlay if nlay else nodes - - rows = parts(rows) - i = 0 - while i < len(rows): - row = rows[i] - if not _leading_word(row): - i += 1 - continue - key = str(row[0]).lower() - f = fields_by_name.get(key) - if f is None: - i += 1 - continue - - dtype = np.int64 if to_field_type(f.type) == "integer" else np.float64 - layered = any(str(t).upper() == "LAYERED" for t in row[1:]) - i += 1 - - if layered: - # Read as many per-layer control records as are actually there, - # rather than assuming exactly `nlay` -- some real-world files - # (mf5to15-converted ones observed so far) tag a field LAYERED - # with fewer rows than nlay (e.g. a single-row TOP); trusting - # nlay blindly would consume the next field's name row as if - # it were layer data. Stops at the first row that isn't a - # recognized control record -- i.e. the next field's row. - # - # Per-record length is min(ncpl, target): correct for a truly - # per-layer field (botm/idomain, shape=(nodes,), target > ncpl) - # *and* for a field tagged LAYERED despite not truly being one - # (delr/delc/top, shape=(ncol,)/(nrow,)/(ncpl,), target <= - # ncpl) -- using ncpl unconditionally there would read far more - # values than the field's one real record has, consuming - # however many subsequent lines (including the next field's - # own name row) it takes to reach ncpl values. - target = _griddata_flat_length(f, dims, nodes) - record_len = min(ncpl, target) if target else ncpl - layers = [] - layer_ios = [] - while i < len(rows): - vrow = rows[i] - if _leading_word(vrow) not in _CONTROL_KINDS: - break - value, j = _read_control_record(rows, i, context, dtype, record_len, f.name) - layer_ios.append(_control_io(vrow, value)) - layers.append(value) - i = j - _record_array_io(arrays, (f.name,), layer_ios, layered=True) - if layers: - # A single-record LAYERED field (see above) is really a - # plain target-shaped array duplicated across nlay -- - # broadcast to it rather than leaving it short - # (concatenating fewer than nlay records would). - stacked = np.concatenate(layers).astype(dtype) - if stacked.size < target and stacked.size and target % stacked.size == 0: - stacked = np.tile(stacked, target // stacked.size) - result[f.name] = stacked - else: - if i >= len(rows): - break - length = _griddata_flat_length(f, dims, nodes) - value, j = _read_control_record(rows, i, context, dtype, length, f.name) - _record_array_io(arrays, (f.name,), [_control_io(rows[i], value)]) - i = j - result[f.name] = value - if f.metadata.get("index") and f.name in result: - result[f.name] = _from_file_index(result[f.name]) - - return result + layered: bool, + name: str = "", +) -> "tuple[np.ndarray | None, list[ArrayIO], int]": + """Read the array field `f`'s control record(s) from ``rows[i]`` (a + block's `parts`) on: one, or with `layered` (its name row said + LAYERED), one per layer. Returns the array, flat and as long as the + field's shape says (see `_Grid.size`), or None if there's no record; + how each record wrote it; and the next row index. `f` is None for an + unknown field, whose records are read only to skip them. `name` + prefixes errors.""" + dtype = np.int64 if f is not None and to_field_type(f.type) == "integer" else np.float64 + size = grid.size(f) + ios: list[ArrayIO] = [] + if layered: + # Read as many per-layer control records as are actually there, + # rather than assuming exactly `nlay` -- some real-world files + # (mf5to15-converted ones observed so far) tag a field LAYERED + # with fewer rows than nlay (e.g. a single-row TOP); trusting + # nlay blindly would consume the next field's name row as if + # it were layer data. Stops at the first row that isn't a + # recognized control record -- i.e. the next field's row. + # + # A record is a layer's (ncpl values), or the whole field's if + # it's smaller (delr/delc/top tagged LAYERED despite not truly + # being layered): reading ncpl there would consume however many + # subsequent lines (including the next field's own name row) it + # takes to reach ncpl values. + record = min(grid.ncpl, size) + layers = [] + while i < len(rows) and _leading_word(rows[i]) in _CONTROL_KINDS: + value, io, i = _read_control_record(rows, i, context, dtype, record, name) + layers.append(value) + ios.append(io) + if not layers: + return None, ios, i + # fewer records than layers repeat, to fill the field + values = np.concatenate(layers).astype(dtype) + if values.size and values.size < size and size % values.size == 0: + values = np.tile(values, size // values.size) + else: + if i >= len(rows): + return None, ios, i + values, io, i = _read_control_record(rows, i, context, dtype, size, name) + ios.append(io) + if f is not None and f.metadata.get("index"): + values = _from_file_index(values) + return values, ios, i + + +def _is_layered(row: list) -> bool: + """Whether an array's name row says LAYERED.""" + return any(str(t).upper() == "LAYERED" for t in row[1:]) def _self_dims_from_kwargs(kwargs: dict) -> dict: @@ -491,113 +538,6 @@ def _names(value: Any) -> list[str]: return [] if value is None else [str(v) for v in np.atleast_1d(value)] -def _parse_readarray_period_block( - rows: list, - ra_fields: dict, - dims: dict, - context: LoadContext, - arrays: "dict | None" = None, -) -> "dict[str, np.ndarray | TimeArraySeriesRef]": - """Arrays by the (lowercase) name they're written under: a field's - name, or an auxiliary variable's, for its named array (see Pass 3b). A - time-array series reference gives the series' name. How each array was - written goes in `arrays` by that name, per `_record_array_io`.""" - nlay = dims.get("nlay", 1) - nodes = dims.get("nodes", 1) - ncpl = nodes // nlay if nlay > 1 else nodes - - result: dict[str, np.ndarray | TimeArraySeriesRef] = {} - rows = parts(rows) - i = 0 - while i < len(rows): - row = rows[i] - if not _leading_word(row): - i += 1 - continue - key = str(row[0]).lower() - f = ra_fields.get(key) - i += 1 - - # A field can come from a time-array series, by name -- - # "RECHARGE TIMEARRAYSERIES " -- instead of a control record on - # the next row. Keep the name (see flopy4.mf6.period_arrays). - tokens = [str(t) for t in row[1:]] - tas = next( - (j for j, t in enumerate(tokens) if t.upper() in ("TIMEARRAYSERIES", "TAS6")), None - ) - if tas is not None: - if f is not None and f.metadata.get("time_series") and tas + 1 < len(tokens): - result[key] = TimeArraySeriesRef(tokens[tas + 1]) - continue - - if f is None: - # Unrecognized field name -- e.g. a per-period AUXILIARY-named - # array (RCHA/EVTA-style: `AUXILIARY ` in OPTIONS lets - # `` appear as its own array field in the period block, - # keyed dynamically, so it's not one of `ra_fields`'s declared - # class fields). Still consume its control-record data so it - # doesn't get mistaken for the *next* real field's row; just - # don't store it (not resolved to a real array yet either). - is_layered_unknown = any(str(t).upper() == "LAYERED" for t in row[1:]) - if is_layered_unknown: - while i < len(rows): - vrow = rows[i] - if _leading_word(vrow) not in _CONTROL_KINDS: - break - _, i = _read_control_record(rows, i, context, np.float64, ncpl, key) - elif i < len(rows): - _, i = _read_control_record(rows, i, context, np.float64, ncpl, key) - continue - - is_int = to_field_type(f.type) == "integer" - # an array is layered only when given with LAYERED (the dfn's - # `layered` flag just allows it); otherwise it covers the field's - # whole shape, all nodes for a grid package - is_layered = any(str(t).upper() == "LAYERED" for t in row[1:]) - per_node = (f.metadata.get("shape") or ("",))[-1] == "nodes" - dtype = np.int64 if is_int else np.float64 - - if is_layered: - layers = [] - layer_ios = [] - while i < len(rows): - vrow = rows[i] - if _leading_word(vrow) not in _CONTROL_KINDS: - break - value, j = _read_control_record(rows, i, context, dtype, ncpl, key) - layer_ios.append(_control_io(vrow, value)) - layers.append(value) - i = j - _record_array_io(arrays, (key,), layer_ios, layered=True) - if layers: - if len(layers) < nlay: - layers = (layers * nlay)[:nlay] - result[key] = np.stack(layers) # (nlay, ncpl) - else: - if i >= len(rows): - break - if _leading_word(rows[i]) == "CONSTANT": - # one value for the period, kept as a 0-d array, as a - # scalar given at construction is (period_arrays._as_array) - v = from_text(rows[i][1], int if dtype == np.int64 else float) - value = np.asarray(v, dtype=dtype) - _record_array_io(arrays, (key,), [_control_io(rows[i], value)]) - i += 1 - result[key] = value - else: - size = nlay * ncpl if per_node else ncpl - value, j = _read_control_record(rows, i, context, dtype, size, key) - _record_array_io(arrays, (key,), [_control_io(rows[i], value)]) - i = j - result[key] = ( - np.asarray(value).reshape(nlay, ncpl) if per_node and nlay > 1 else value - ) - if f.metadata.get("index") and isinstance(arr := result.get(key), np.ndarray): - result[key] = np.asarray(_from_file_index(arr)) - - return result - - def _disambiguate_ga_variant(candidates: "list[type[Component]]", path: Path) -> "type[Component]": """ Pick between a base package class and its G/A-variant sibling @@ -625,157 +565,87 @@ def _disambiguate_ga_variant(candidates: "list[type[Component]]", path: Path) -> return candidates[0] -def _resolve_bindings(cls: type, raw_lower: dict, context: LoadContext) -> dict[str, Any]: - """Resolve packages/models/exchanges/solutiongroup-style binding rows - into loaded child component instances, keyed by field name -- merged - into `structure_component`'s kwargs so children are attached the same - way manual construction already attaches them (`Gwf(dis=Dis(...))`). - - Child-Component fields are found via `child_field_candidates()` - (mirroring `unstructure.py`'s `_make_binding_blocks`, the egress side of - this same job), grouped by block name since several fields can share one - block (every `Gwf` package field shares `"packages"`). Within a block, - `DimensionProvider` targets (`dis`/`disv`/`disu`) are resolved first so - their dims can be threaded into the context of that block's other - children -- `dimensions.py`'s object-graph walk only helps once a child - is already attached, not while its siblings are still loading. A row's - columns are read as its field's ``row`` says (see `converter.binding`). - Its references (an exchange's models) resolve among the models loaded - so far, from the models block, which comes first (field order), and go - in the child's context as well. - """ - from flopy4.attrs_xarray import child_field_candidates - from flopy4.mf6.model import Model - - # Model scope to prefer when resolving this class's own binding rows' - # ftype tokens via get_ftype() below -- e.g. structuring a Gwf's - # "packages" block should resolve "DIS6" to gwf's own Dis, not gwt's/ - # gwe's/prt's. - # A Model class's __module__ is "flopy4.mf6." (defined directly - # in that subpackage's __init__.py), not "...." like its - # child packages, so this can't reuse component.py's _model_prefix -- - # a Model's own class name *is* its model prefix by convention. - model_prefix = cls.__name__.lower() if issubclass(cls, Model) else None - - fields_by_block: dict[str, list] = {} - # Blocks with other fields too. In the rest, every row names a child (a - # model's packages, the simulation's models), and a row no field takes, - # as for a package flopy4 has no class for yet, warns. - mixed: set[str] = set() - for f in attrs.fields(cls): # type: ignore[arg-type] - spec = child_field_candidates(f) if f.metadata.get("child") else None - if spec is None or f.metadata.get("_keyword"): - if (block := f.metadata.get("block")) is not None: - mixed.add(block) - if spec is None: - continue - block_name = f.metadata.get("block") - if block_name is None or f.metadata.get("_keyword"): - continue # file records' children load with their records - kind, candidates = spec - columns = f.metadata["row"] - fields_by_block.setdefault(block_name, []).append((f.name, kind, candidates, columns)) +def _binding_classes(accepted: tuple[type, ...]) -> "list[type[Component]]": + """The classes a child field takes, as concrete ones: an abstract + one (the simulation's `Model`, `Exchange`, `Solution`) as each + component class deriving from it.""" + out: "list[type[Component]]" = [] + for c in accepted: + if ABC in c.__bases__: + out += [k for k in dict.fromkeys(get_ftypes().values()) if issubclass(k, c)] + else: + out.append(cast("type[Component]", c)) + return out - if not fields_by_block: - return {} +def _binding_target(row: list, field_specs: list, context: LoadContext) -> tuple | None: + """The child field a row names (``CHD6 ``) and the class + to load it as, by the row's ftype, read as the field's ``row`` says, + or None if no field takes it. A G/A pair (`Chd`/`Chdg`) shares one + ftype, so is told apart by the file's options (see + `_disambiguate_ga_variant`).""" + matches = [] + for f, kind, accepted in field_specs: + token = str(row[f.metadata["row"].index("ftype")]).lower() + matches += [(f, kind, c) for c in _binding_classes(accepted) if c.ftype.lower() == token] + if len(matches) > 1: + fname = str(row[matches[0][0].metadata["row"].index("filename")]) + target = _disambiguate_ga_variant([c for *_, c in matches], context.resolve(fname)) + return next(m for m in matches if m[2] is target) + return matches[0] if matches else None + + +def _resolve_bindings(cls: type, rows_by_block: dict, context: LoadContext) -> dict[str, Any]: + """The children the rows of `cls`'s blocks name (a model's packages, + the simulation's models, exchanges and solutions), loaded, by field: + the kwargs construction attaches them by (`Gwf(dis=Dis(...))`). + Egress's `_Unstructure.bindings` is the inverse. + + A block's dims providers (`dis`/`disv`/`disu`) load first, so the + rest load with their dims; the object-graph walk in `dimensions.py` + only finds them once the children are attached. A row's columns are + read as its field's ``row`` says (see `converter.binding`). Its + references (an exchange's models) resolve among the models loaded so + far, from the models block, which comes first (field order), and go + in the child's context as well.""" kwargs: dict[str, Any] = {} - for block_name, field_specs in fields_by_block.items(): - # Some binding blocks are numbered (e.g. "SOLUTIONGROUP 1", like - # "PERIOD 1" elsewhere) -- gather every raw block whose name matches - # or starts with "{block_name} ". - raw_names = [ - raw_name - for raw_name in raw_lower - if raw_name == block_name or raw_name.startswith(f"{block_name} ") - ] - # several solution groups, each with its own MXITER, would be - # merged into one, which MF6 runs differently - if block_name == "solutiongroup" and len(raw_names) > 1: - groups = ", ".join(n.upper() for n in raw_names) - raise ValueError( - f"{cls.__name__}: more than one solution group ({groups}); only one is supported" - ) - rows = [row for raw_name in raw_names for row in raw_lower[raw_name]] - if not rows: - continue - - # Resolve each row's target class + owning field up front, so rows - # can be reordered (dims providers first) without re-parsing. - resolved = [] - for row in rows: + for block_name, field_specs in binding_fields(cls).items(): + targets = [] + for row in rows_by_block.get(block_name) or []: if not row: continue - for child_name, kind, accepted, columns in field_specs: - token = str(row[columns.index("ftype")]).lower() - # Concrete candidates first: compare each accepted class's - # own ftype directly to the row's token. G/A-variant pairs - # (Chd/Chdg, Rch/Rcha, ...) share one namefile ftype (real - # MF6 has no separate 'CHDG6' case, only 'CHD6' -- see - # Component.ftype), so more than one concrete - # candidate can match; disambiguate from the file content. - concrete = [c for c in accepted if ABC not in c.__bases__] - matches = [c for c in concrete if c.ftype.lower() == token] - if len(matches) > 1: - fname = str(row[columns.index("filename")]) - target_cls = _disambiguate_ga_variant(matches, context.resolve(fname)) - elif matches: - target_cls = matches[0] - else: - # Fall back to the ftype registry for abstract-typed - # fields (Model/Exchange/Solution), where the - # field's declared type can't be compared to a token - # directly. - resolved_cls = get_ftype(token, prefix=model_prefix) - if resolved_cls is None or not any( - issubclass(resolved_cls, t) for t in accepted - ): - continue - target_cls = resolved_cls - - resolved.append((row, target_cls, child_name, kind, columns)) - break - else: - if block_name in mixed: - continue + if (target := _binding_target(row, field_specs, context)) is None: + # a package flopy4 has no class for yet, say warnings.warn( f"{cls.__name__}: no field takes {block_name} entry " f"{str(row[0]).upper()} ({row[1] if len(row) > 1 else ''}), skipped", UserWarning, stacklevel=2, ) + continue + targets.append((row, *target)) + targets.sort(key=lambda t: not issubclass(t[3], DimensionProvider)) - resolved.sort(key=lambda r: 0 if issubclass(r[1], DimensionProvider) else 1) - - dims: dict = {} - collectors: dict[str, Any] = {} - for row, target_cls, child_name, kind, columns in resolved: - values = read_row(row, columns, target_cls, kwargs.get("models", [])) + child_context = attrs.evolve(context, dims={}, parent=None) + for row, f, kind, target_cls in targets: + values = read_row(row, f.metadata["row"], target_cls, kwargs.get("models", [])) fname = str(values.pop("filename")) name = values.pop("name", None) values.pop("ftype") # the rest are references, set like a built child's - referenced_models = [v for value in values.values() for v in referenced(value)] - child_context = attrs.evolve( - context, - dims=dims, - parent=None, - models=tuple(referenced_models) or None, - ) - child = target_cls.load(context.resolve(fname), name=name, context=child_context) + refs = [v for value in values.values() for v in referenced(value)] + load_context = attrs.evolve(child_context, models=tuple(refs) or None) + child = target_cls.load(context.resolve(fname), name=name, context=load_context) child.filename = Path(fname) for attr, value in values.items(): setattr(child, attr, value) if isinstance(child, DimensionProvider): - dims = {**dims, **child.get_dims()} - - if kind == "only": - collectors[child_name] = child - elif kind == "list": - collectors.setdefault(child_name, []).append(child) - - kwargs.update(collectors) - + dims = {**child_context.dims, **child.get_dims()} + child_context = attrs.evolve(child_context, dims=dims) + if kind == "list": + kwargs.setdefault(f.name, []).append(child) + else: + kwargs[f.name] = child return kwargs @@ -827,20 +697,457 @@ def _load_file_child(field: Any, path: Path, context: LoadContext) -> Any: return child -def _group_repeating_rows( - raw_lower: dict, prefixes: "set[str]", cast -) -> "dict[str, dict[Any, list]]": - grouped: dict[str, dict[Any, list]] = {} - for block_name, rows in raw_lower.items(): - names = block_name.split() - if len(names) < 2 or names[0] not in prefixes: +def _init_key(f: attrs.Attribute) -> str: + """The `__init__` argument setting the field `f`: its alias (a private + field's name without the underscore, as ``stress_period_data``), else + its name.""" + return f.alias or f.name + + +def _is_grid_array(f: Any) -> bool: + """Whether `f` holds a numeric array read with control records + (griddata, a G/A period's, a TAS time's), not inline (AUXILIARY's).""" + return is_array(f) and to_field_type(f.type) in ("integer", "double") + + +def _per_header(f: attrs.Attribute) -> bool: + """Whether the field `f`, of a repeating block, holds a value per + header (a period's, a time's, an OBS output file's), not one.""" + return get_origin(unwrap_optional(f.type)) is dict or block_list_type(f.type) is not None + + +def _header(cls: "type[Component]", block: str, words: list[str]) -> Any: + """A repeating block's header, from the words after its name, by its + kind in ``cls.headers``, as both loaders key its occurrences: an index + (a period's IPER) 0-based, another integer (SOLUTIONGROUP's) or a + double (a TAS time) as a number, a record (OBS's ``FILEOUT ``) + as its words, case kept. Raises ValueError if there are none, or a + number's doesn't parse.""" + if not words: + raise ValueError(f"no {block} header") + header = cls.headers[block] + if header.kind == "integer": + n = int(words[0]) + return n - 1 if header.index else n + if header.kind == "double": + return fortran_float(words[0]) + return tuple(words) + + +def _occurrences(raw: dict, cls: "type[Component]") -> dict[str, dict[Any, list]]: + """The file's blocks by name, each as ``{None: rows}``, or for a + repeating block ``{header: rows}`` (see `_header`) in file order. MF6 + ignores a block it doesn't read (an old IMS file's XMD), so one the + class doesn't have warns and is skipped; so, silently, is a repeating + one whose header doesn't parse.""" + blocks = file_blocks(cls) + found: dict[str, dict[Any, list]] = {} + for raw_name, rows in raw.items(): + name, *tokens = raw_name.lower().split() + if name not in blocks: + if rows: + warnings.warn(f"{cls.__name__}: ignoring unknown block {raw_name.upper()}") continue + header = None + if name in cls.headers: + try: + header = _header(cls, name, raw_name.split()[1:]) + except ValueError: + continue + found.setdefault(name, {})[header] = rows + return found + + +def _period_array( + value: np.ndarray, ios: "list[ArrayIO]", f: Any, grid: _Grid, layered: bool +) -> np.ndarray: + """A G/A period's array as the field holds it (see + flopy4.mf6.period_arrays): a LAYERED one by layer, a CONSTANT one as + its value (0-d, as a scalar given at construction is), a nodes-shaped + one by layer, else flat.""" + if layered: + layers = value.reshape(-1, grid.ncpl) # (nlay, ncpl) + # fewer records than layers repeat + return layers if len(layers) >= grid.nlay else np.resize(layers, (grid.nlay, grid.ncpl)) + if ios[0].format == "constant": + return np.asarray(value[0]) + if (f.metadata.get("shape") or ("",))[-1] == "nodes" and grid.nlay > 1: + return value.reshape(grid.nlay, grid.ncpl) + return value + + +class ComponentLoad: + """What any loader's read of one component's file builds: its + `__init__` arguments, so far; how the file wrote each array; and the + rows naming children, for `_resolve_bindings`. Its fields are read a + block at a time in file-schema order, options and dimensions first, so + a block can read by those before it (the auxiliary names, the sizes + and switches of a list's columns, a dims provider's own dims).""" + + def __init__(self, cls: type, context: LoadContext) -> None: + self.cls = cls + self.context = context + self.kwargs: dict[str, Any] = {} + # how the file wrote each array, by `ArrayKey`, and list, by + # `ListKey`, for the instance's write_context + self.array_ios: dict = {} + self.list_ios: dict = {} + self.bindings: dict[str, list] = {} + self._children: dict[Path, Any] = {} + self._union_arm = _union_arm(context.parent) + self._union_forms = _union_forms(context.parent) + # the child fields named by each block's rows + self.binding_blocks = binding_fields(cls) + + @property + def dims(self) -> dict: + """The grid's dims: the context's, or for a dims provider, which + has none yet, its own (see `_self_dims_from_kwargs`).""" + return dict(self.context.dims) or _self_dims_from_kwargs(self.kwargs) + + def finish(self, name: str | None = None) -> Any: + """The component, from the arguments read, with its children + loaded from the rows naming them and its arrays written back the + way the file wrote them.""" + kwargs = self.kwargs + if self.context.workspace and self.bindings: + kwargs.update(_resolve_bindings(self.cls, self.bindings, self.context)) + if name is not None: + kwargs["name"] = name + if self.array_ios or self.list_ios: + kwargs["write_context"] = WriteContext(arrays=self.array_ios, lists=self.list_ios) + return self.cls(**kwargs) + + def read_blocks( + self, + name: str, + fields: list, + found: dict[Any, Any], + *, + numbered: bool, + fill_forward: bool, + ) -> None: + """Read the occurrences of the block `name`, ``{header: contents}`` + (``{None: contents}`` for a block that doesn't repeat), into the + arguments: its `fields`' values, or a repeating block's by header, + in order if `numbered`. An empty occurrence of a `fill_forward` + block (a period) clears its lists and, for a grid package, its + arrays. `body` reads each occurrence's contents.""" + if None in found: + for f, value in self.body(name, found[None], None).items(): + self.kwargs[_init_key(f)] = value + return + if len(found) > 1 and not any(_per_header(f) for f in fields): + # several solution groups, each with its own MXITER, would be + # merged into one, which MF6 runs differently + names = ", ".join(f"{name.upper()} {h}" for h in found) + raise ValueError( + f"{self.cls.__name__}: more than one {name} block ({names}); only one is supported" + ) + values: dict[attrs.Attribute, dict] = {} + for header in sorted(found) if numbered else found: + if contents := found[header]: + body = self.body(name, contents, header) + elif fill_forward: + body = self.cleared(fields) + else: + body = {} + for f, value in body.items(): + values.setdefault(f, {})[header] = value + for f in fields: + if (blocks := block_list_type(f.type)) is not None: + header_cls, list_name, _ = blocks.parts() + self.kwargs[_init_key(f)] = [ + blocks( + **{ + blocks._header: header_cls.from_tokens(list(header)), + list_name: values.get(f, {}).get(header) or [], + } + ) + for header in found + ] + elif f in values: + by_header = values[f] + self.kwargs[_init_key(f)] = ( + by_header if _per_header(f) else next(iter(by_header.values())) + ) + + def body(self, name: str, contents: Any, header: Any) -> dict: + """The values of one occurrence of the block `name`, by field.""" + raise NotImplementedError + + def cleared(self, fields: list) -> dict: + """An empty period's values: no rows for each list, and for a grid + package, no array.""" + lists: dict[Any, Any] = {f: [] for f in fields if item_list_type(f.type) is not None} + if not is_grid_package(self.cls): + return lists + return lists | {f: None for f in fields if _is_grid_array(f) and not f.metadata.get("fk")} + + def layout(self, item_cls: Any) -> tuple[dict[str, int], frozenset[str]]: + """The sizes (aux by auxiliary, GNC's alphasj by numalphaj) and + switches (boundnames) of a list's columns, as read so far.""" + sizes = {} + for shape in sized_by(item_cls): + n = dim_value(shape, lookup=lambda name: dim_lookup(self.kwargs, name)) + if n is not None: + sizes[shape] = n + enabled = frozenset(o for o in conditional_fields(item_cls).values() if self.kwargs.get(o)) + return sizes, enabled + + def parse_list(self, rows: list, item_cls: Any, words: tuple[str, ...] = ()) -> Any: + """A list field's value from its rows, laid out as `layout` says.""" + sizes, enabled = self.layout(item_cls) + return _parse_rows( + rows, + item_cls, + sizes=sizes, + enabled=enabled, + # the grid's dims give the cellids' width (see LoadContext.ncelldim) + context=attrs.evolve(self.context, dims=self.dims), + union_arm=self._union_arm, + union_forms=self._union_forms, + load_child=self.load_child, + words=words, + ) + + def load_child(self, f: Any, token: str) -> Any: + """A row's child column (LAK's TAB6 file), loaded from its file, + once per file (SFR's periods may name one table again).""" + path = Path(_strip_quotes(token)) + if path not in self._children: + context = attrs.evolve(self.context, dims=self.dims, parent=self.cls) + self._children[path] = _load_file_child(f, path, context) + return self._children[path] + + +class _Load(ComponentLoad): + """The basic loader's read of one component's file, a block at a time + in file-schema order (see `ComponentLoad`).""" + + def __init__(self, cls: type, context: LoadContext) -> None: + super().__init__(cls, context) + self._fields = attrs.fields_dict(cls) + + def value_at(self, path: str) -> Any: + """The value read so far for the field at `path` (``block.field``).""" + a = self._fields.get(path.split(".", 1)[1]) + return None if a is None else self.kwargs.get(_init_key(a)) + + def read(self, name: str, found: dict[Any, list]) -> None: + """Read the occurrences of the block `name` into the arguments + (see `ComponentLoad.read_blocks`).""" + fields = file_blocks(self.cls)[name] + header = cast("type[Component]", self.cls).headers.get(name) + self.read_blocks( + name, + fields, + found, + numbered=header is not None and header.kind in ("integer", "double"), + fill_forward=any(f.metadata.get("fill_forward") for f in fields), + ) + + def body(self, name: str, rows: list, header: Any) -> dict: + """The values of one occurrence of the block `name`, by field. A + row whose first word is a tagged field's key is that field's; the + rest are the block's untagged field's, or name children (see + `_resolve_bindings`). An array's name row comes with its control + records (see `_groups`). A tagged list collects its rows. An + unknown word warns, and its records are skipped.""" + keys = block_keys(self.cls, name) + binds = name in self.binding_blocks + untagged = keys.untagged + keyed = keys.tagged or keys.dynamic or keys.computed + if not keyed and not binds: + value = None if untagged is None else self.untagged(untagged, rows, header) + return {} if value is None else {untagged: value} + written = rows + rows = _resolve_open_close_rows(rows, self.context) + if not keyed: + self.bindings.setdefault(name, []).extend(rows) + return {} + + values: dict[attrs.Attribute, Any] = {} + lists: dict[attrs.Attribute, list] = {} + rest: list = [] + for head, *records in _groups(parts(rows)): + if _leading_word(head).lower() in keys.computed: + self.check_computed(name, head) + continue + if (found := self.field_of(keys, head)) is None: + if binds or untagged is not None: + rest += _rows_of([head, *records]) + elif not _is_record(head): + self.unknown(name, head) + continue + a, aux_name = found + if _is_grid_array(a): + self.array(a, aux_name, [head, *records], header, values) + elif item_list_type(a.type) is not None: + lists.setdefault(a, []).append(head) + elif a.metadata.get("_keyword"): + self.file(a, head, values) + else: + values[a] = _tagged_value(a, head) + for a, list_rows in lists.items(): + item_cls = item_list_type(a.type) + value = self.parse_list(list_rows, item_cls, item_list_words(a.type)) + if value is not None: + values[a] = value + self.record_list_io(a, written, value, item_cls, header) + if binds: + self.bindings.setdefault(name, []).extend(rest) + elif untagged is not None and rest: + if (value := self.untagged(untagged, rest, header)) is not None: + values[untagged] = value + return values + + def field_of(self, keys: BlockKeys, row: Any) -> "tuple[Any, str | None] | None": + """The field whose row `row` is, by its first word, with the + name a dynamic key gives (an auxiliary variable's); None for a row + of numbers, or a word no field's. A dynamic key wins: an auxiliary + name that matches a field's (Q) is the aux array, as in MF6. Where + a word begins several fields' rows (OC's HEAD), the next one tells + them apart; a file record's row has its direction, so OC's ``HEAD + PRINT_FORMAT`` isn't a ``HEAD FILEOUT `` record.""" + word = _leading_word(row).lower() + if not word: + return None + for path, f in keys.dynamic.items(): + for n in _names(self.value_at(path)): + if n.lower() == word: + return f, n + following = str(row[1]).lower() if len(row) > 1 else "" + candidates = keys.tagged.get(word, ()) + if len(candidates) > 1: + candidates = tuple(f for f in candidates if following in following_tags(f)) or tuple( + f for f in candidates if not following_tags(f) + ) + if not candidates: + return None + if following_tags(candidates[0]) in (["filein"], ["fileout"]) and following not in ( + "filein", + "fileout", + ): + return None + return candidates[0], None + + def unknown(self, name: str, row: list) -> None: + """Warn of a row no field of the block `name` takes. MF6 rejects a + keyword it doesn't know, so this is likely one flopy4 doesn't + support yet.""" + key = str(row[0]).upper() + warnings.warn( + f"{self.cls.__name__}: no field takes {name.upper()} entry {key}, skipped", + UserWarning, + stacklevel=4, + ) + + def check_computed(self, name: str, row: list) -> None: + """Check the row of a computed field (see `computed_fields`). Its + value is derived, not read, but MF6 stops on a bad one, so don't load + what it wouldn't run.""" try: - header = cast(names[1]) - except ValueError: - continue - grouped.setdefault(names[0], {})[header] = rows - return grouped + from_text(row[1], int) + except (IndexError, ValueError): + entry = " ".join(str(t) for t in row).upper() + raise ValueError( + f"{self.cls.__name__}: {name.upper()} entry {entry} needs an integer" + ) from None + + def array(self, f: Any, aux_name: "str | None", rows: list, header: Any, values: dict) -> None: + """Read the grid array `f`, from its name row and control records + (`rows`), into `values`, and how the file wrote it, by `ArrayKey`, + into `array_ios`; an auxiliary variable's (`aux_name`) into `f`'s + value by that name. A field can come from a time-array series, by + name -- ``RECHARGE TIMEARRAYSERIES `` -- instead of a control + record; its value keeps the name (see flopy4.mf6.period_arrays).""" + row = rows[0] + if (grid := _Grid.of(self.dims)) is None: + return + tokens = [str(t) for t in row[1:]] + tas = next( + (j for j, t in enumerate(tokens) if t.upper() in ("TIMEARRAYSERIES", "TAS6")), None + ) + value: Any + if tas is not None: + if not f.metadata.get("time_series") or tas + 1 >= len(tokens): + return + value = TimeArraySeriesRef(tokens[tas + 1]) + else: + # An array is layered only when given with LAYERED (the dfn's + # `layered` flag just allows it); otherwise it covers the + # field's whole shape, all nodes for a grid package. + layered = _is_layered(row) + value, ios, _ = _read_array(rows, 1, f, grid, self.context, layered, aux_name or f.name) + if aux_name is None: + key = (f.name,) if header is None else (f.name, header) + _record_array_io(self.array_ios, key, ios, layered=layered) + if value is None: + return + if header is not None: + value = _period_array(value, ios, f, grid, layered) + if aux_name is None: + values[f] = value + else: + values.setdefault(f, {})[aux_name] = value + + def file(self, f: Any, row: list, values: dict) -> None: + """A file record's value (``KEYWORD [FILEIN|FILEOUT] ``) into + `values`: its path, or the child loaded from it. A list of them (a + DFN tagged list of file records) gets one element per row.""" + has_direction = len(row) > 1 and str(row[1]).upper() in ("FILEIN", "FILEOUT") + tokens = row[2:] if has_direction else row[1:] + if not tokens: + return + path = Path(_strip_quotes(str(tokens[0]))) + value = ( + _load_file_child(f, path, attrs.evolve(self.context, parent=self.cls)) + if f.metadata.get("child") + else path + ) + if get_origin(unwrap_optional(f.type)) is list: + values.setdefault(f, []).append(value) + else: + values[f] = value + + def from_files(self, rows: list, item_cls: Any) -> list: + """A list's rows: its block's, or those of the file (see + `_resolve_open_close_rows`) that its only row names.""" + sizes, enabled = self.layout(item_cls) + context = attrs.evolve(self.context, dims=self.dims) + return _resolve_open_close_rows(rows, context, item_cls, sizes, enabled) + + def untagged_list(self, f: Any, rows: list, item_cls: Any, header: Any) -> Any: + """An untagged list's value (see `record_list_io`).""" + value = self.parse_list(self.from_files(rows, item_cls), item_cls, item_list_words(f.type)) + self.record_list_io(f, rows, value, item_cls, header) + return value + + def record_list_io(self, f: Any, rows: list, value: Any, item_cls: Any, header: Any) -> None: + """Record how the block (its `rows`, as written) wrote the list + `f`, if to a file, in `list_ios` by `ListKey`.""" + context = attrs.evolve(self.context, dims=self.dims) + if (io := _list_io(rows, value, item_cls, context)) is not None: + key = _list_key(f) + self.list_ios[key if header is None else (key, header)] = io + + def untagged(self, f: Any, rows: list, header: Any = None) -> Any: + """The value of a block's untagged field from its rows: a list's + elements (an OBS output file's, for a list of blocks), a TAS + time's array, a control record with no name row, or a word (STO's + steady-state or transient), its first row's first, as MF6 reads it.""" + if (item_cls := item_list_type(f.type)) is not None: + return self.untagged_list(f, rows, item_cls, header) + if (blocks := block_list_type(f.type)) is not None: + item_cls = blocks.parts()[2] + return self.parse_list(self.from_files(rows, item_cls), item_cls) + if _is_grid_array(f) and (grid := _Grid.of(self.dims)) is not None: + value, _, _ = _read_array(parts(rows), 0, f, grid, self.context, False, f.name) + return value + if f.metadata.get("type") == "string" and rows and rows[0]: + return str(rows[0][0]) + return None def structure_component( @@ -852,13 +1159,19 @@ def structure_component( ) -> Any: """Reconstruct a component instance from a raw parsed MF6 input dict. + The file's blocks are read in the order of ``cls``'s fields, options + and dimensions first (see `file_blocks`). Each row goes + to the field of its block whose key it begins with, else to the + block's untagged field; a repeating block's values are kept by header + (see `_occurrences`). The rows naming children are resolved last (see + `_resolve_bindings`). + Parameters ---------- raw : dict Output of ``loads()`` — {BLOCK_NAME_UPPER: list_of_token_rows}. cls : type - The component class to instantiate. Fields are read via their - ``block`` metadata (see ``flopy4.mf6.spec``). + The component class to instantiate. context : LoadContext, optional Where the file sits in the simulation: the workspace relative paths resolve against, the grid dims (e.g. {"nlay": 3, "nodes": @@ -879,467 +1192,11 @@ def structure_component( ------- Component instance. """ - context = context or LoadContext() - dims = dict(context.dims) - raw_lower = {k.lower(): v for k, v in raw.items()} - binding_kwargs = _resolve_bindings(cls, raw_lower, context) if context.workspace else {} - - # Only DFN-block-derived fields -- excludes identity/bookkeeping - # attributes (Component.name, filename, ...) with no `block` metadata, - # so a block keyword can't shadow them (e.g. utl-tas's "NAME ..." row - # is for time_series_name, not Package.name). - all_fields = { - f.name: f for f in attrs.fields(cls) if f.init is not False and "block" in f.metadata - } - alias_map: dict[str, str] = {} # alias → name - for f in attrs.fields(cls): - if f.alias and f.alias != f.name: - alias_map[f.alias] = f.name - - # Block-level file records ("TS6 FILEIN ") are keyed by their - # trigger keyword, the path field's _keyword metadata (see spec.file), - # not by the field's py name (ts_file). - file_fields: dict[str, Any] = { - f.metadata["_keyword"]: f for f in all_fields.values() if f.metadata.get("_keyword") - } - - # Index Optional[InnerClass] fields by the inner class's _keyword (lowercase). - # Covers options-block compound records like Npf.Cvoptions, Ims.Rclose, etc. - inner_class_fields: dict[str, tuple] = {} - for f in attrs.fields(cls): - if f.init is False: - continue - inner_cls = _inner_class_type(f.type) - if inner_cls is None: - continue - if kw := vars(inner_cls).get("_keyword", ""): - for k in (kw, *vars(inner_cls).get("_aliases", ())): - inner_class_fields[k.lower()] = (f, inner_cls) - - # Identify Item-list fields (packagedata, connectiondata, partitions …) -- - # the field's own type annotation (Optional[list[ItemClass]] or - # Optional[dict[int, list[ItemClass]]]) is the schema. One alone in its - # block takes all the block's rows; one sharing its block with other - # fields (a DFN tagged list) takes the rows starting with its elements' - # keyword(s). - block_item_fields: dict[str, tuple] = {} # block_name → (field, item_cls) - keyword_item_fields: dict[str, tuple] = {} # keyword → (field, item_cls) - period_field = None # field for the period Item-list - period_item_cls: "type[Item] | tuple[type[Item], ...] | None" = None - - # Fill-forward repeating blocks (period), per the fields' own - # fill_forward metadata (from the DFN's BlockHeader.fill_forward). - fill_forward_blocks = { - f.metadata["block"] for f in attrs.fields(cls) if f.metadata.get("fill_forward") - } - block_sizes = Counter(f.metadata["block"] for f in all_fields.values()) - - for f in attrs.fields(cls): - block = f.metadata.get("block", "") - item_cls = item_list_type(f.type) - if item_cls is None: - continue - if f.metadata.get("fill_forward"): - period_field = f - period_item_cls = item_cls - elif block_sizes[block] == 1: - block_item_fields[block] = (f, item_cls) - else: - for elem_cls in item_cls if isinstance(item_cls, tuple) else (item_cls,): - keyword_item_fields[elem_cls.keyword().lower()] = (f, elem_cls) - - # Array fields whose own block repeats per header value -- e.g. - # utl-tas's tas_array, dict[float, ndarray]. Detected structurally from - # the field's own annotation (Optional[dict[K, ArrayLike]]), the same - # way block_item_fields above is detected via item_list_type -- not via - # a metadata flag. Mirrors egress/unstructure.py's write path. - repeating_array_fields = { - f.name: f - for f in attrs.fields(cls) - if repeating_array_key_type(f.type) is not None - and not f.metadata.get("fill_forward") - and f.init is not False - and not f.metadata.get("fk") - } - repeating_array_block_prefixes = {f.metadata["block"] for f in repeating_array_fields.values()} - - # Blocks of plain numeric arrays, read by Pass 4: GRIDDATA, and DISU's - # CONNECTIONDATA. - array_fields: dict[str, dict[str, Any]] = {} - for f in all_fields.values(): - if ( - is_array(f) - and not f.metadata.get("fill_forward") - and f.name not in repeating_array_fields - and item_list_type(f.type) is None - and to_field_type(f.type) in ("integer", "double") - ): - array_fields.setdefault(f.metadata["block"], {})[f.name] = f - - # Blocks repeating under a record header (OBS's CONTINUOUS), by block. - header_block_fields = { - f.metadata["block"]: (f, b) for f in attrs.fields(cls) if (b := block_list_type(f.type)) - } - - # ── Pass 1: scalar blocks (options, dimensions, etc.) ──────────────────── - known_blocks = {f.metadata.get("block") for f in attrs.fields(cls)} - # Blocks naming children (a model's packages, the simulation's - # solutions), whose rows _resolve_bindings takes, and warns for. - binding_blocks = { - f.metadata.get("block") - for f in attrs.fields(cls) - if f.metadata.get("child") and not f.metadata.get("_keyword") - } - if isinstance(getattr(cls, "maxbound", None), property): - known_blocks.add("dimensions") # computed maxbound, see unstructure.py - kwargs: dict[str, Any] = {} - # how the file wrote each array, by `ArrayKey`, and list, by `ListKey`, - # for the instance's write_context - array_ios: dict = {} - list_ios: dict = {} - for block_name, rows in raw_lower.items(): - if not rows: - continue - if block_name.split()[0] not in known_blocks: - # MF6 ignores blocks it doesn't read (an old IMS file's XMD) - warnings.warn(f"{cls.__name__}: ignoring unknown block {block_name.upper()}") - continue - if ( - block_name in block_item_fields - or block_name.split()[0] in fill_forward_blocks - or block_name in array_fields - or block_name.split()[0] in repeating_array_block_prefixes - or block_name.split()[0] in header_block_fields - ): - continue - rows = _resolve_open_close_rows(rows, context) - for row in rows: - if not row: - continue - key = str(row[0]).lower() - has_direction = len(row) > 1 and str(row[1]).upper() in ("FILEIN", "FILEOUT") - # A file record has its direction token, so OC's "HEAD - # PRINT_FORMAT ..." isn't the "HEAD FILEOUT " record. - if (ff := file_fields.get(key)) is not None and ( - has_direction or not ff.metadata.get("direction") - ): - # KEYWORD FILEIN|FILEOUT : the path follows the - # keyword and the direction token. - tokens = row[2:] if has_direction else row[1:] - if tokens: - path = Path(_strip_quotes(str(tokens[0]))) - init_key = ff.alias or ff.name - if ff.metadata.get("child"): - child = _load_file_child(ff, path, attrs.evolve(context, parent=cls)) - if get_origin(unwrap_optional(ff.type)) is list: - kwargs.setdefault(init_key, []).append(child) - else: - kwargs[init_key] = child - continue - # A list[Path] field (a DFN tagged list of file - # records) gets one element per row. - if get_origin(unwrap_optional(ff.type)) is list: - kwargs.setdefault(init_key, []).append(path) - else: - kwargs[init_key] = path - continue - if (kf := keyword_item_fields.get(key)) is not None: - # One element of an Item list sharing its block with other - # fields (a DFN tagged list), by its leading keyword. - f, item_cls = kf - kwargs.setdefault(f.alias or f.name, []).append(item_cls.from_tokens(row)) - continue - # A record's keyword wins over a field's name: utl-ts's SFAC is - # sfacrecord_single's keyword, and the SFACS record's field name. - if key in inner_class_fields: - cand_f, inner_cls = inner_class_fields[key] - cand_init = cand_f.alias if cand_f.alias else cand_f.name - kwargs[cand_init] = inner_cls.from_tokens(row) - continue - # keywords are renamed with a trailing underscore (CONTINUE: continue_) - f = ( - all_fields.get(key) - or all_fields.get(alias_map.get(key, "")) - or all_fields.get(f"{key}_") - ) - if f is None: - # MF6 rejects a keyword it doesn't know, so this is likely - # one flopy4 doesn't support yet, or a developmode one the - # classes were synced without. A computed one (a list - # package's MAXBOUND) is derived, not read. - if block_name.split()[0] not in binding_blocks and not isinstance( - getattr(cls, key, None), property - ): - warnings.warn( - f"{cls.__name__}: no field takes {block_name.upper()} entry " - f"{str(row[0]).upper()}, skipped", - UserWarning, - stacklevel=2, - ) - continue - init_key = f.alias if f.alias else f.name - # A Record-typed field must go through from_tokens(), even when - # the matched token is the field's own name rather than the - # record's trigger keyword. - inner_cls = _inner_class_type(f.type) - if inner_cls is not None: - kwargs[init_key] = inner_cls.from_tokens(row) - continue - # Take what the field's type needs from the row; MF6 ignores - # anything after it (often an inline comment, or a second value - # like IMS's `UNDER_RELAXATION NONE DBD`). - t = unwrap_optional(f.type) - if t is bool: - kwargs[init_key] = True - elif get_origin(t) in (list, np.ndarray, npt.NDArray): - # inline arrays (AUXILIARY's names), even with one element; numpy - # >= 2.5's NDArray[X] has origin NDArray, not ndarray - args = get_args(t) - elem = args[-1] if get_origin(t) is not list else (args[0] if args else Any) - if get_origin(elem) is np.dtype: - elem = get_args(elem)[0] if get_args(elem) else Any - elem = {np.int64: int, np.float64: float, np.str_: str}.get(elem, elem) - kwargs[init_key] = [from_text(v, elem) for v in row[1:]] - else: - kwargs[init_key] = from_text(row[1], t) - - item_types = [ic for _, ic in block_item_fields.values()] - if period_item_cls is not None: - item_types.append(period_item_cls) - # Sizes of the package fields and dimensions sizing item columns - # (aux by auxiliary, GNC's alphasj by numalphaj). - sizes = {} - for ic in item_types: - for shape in sized_by(ic): - if (n := dim_value(shape, lookup=lambda name: dim_lookup(kwargs, name))) is not None: - sizes[shape] = n - enabled = frozenset( - o for ic in item_types for o in conditional_fields(ic).values() if kwargs.get(o) - ) - - # The grid's dims give the cellids' width (see LoadContext.ncelldim). - # Same "self dims, since a DimensionProvider has none threaded to it - # yet" fallback as Pass 4's griddata parsing. - effective_dims = dims or _self_dims_from_kwargs(kwargs) - rows_context = attrs.evolve(context, dims=effective_dims) - union_arm = _union_arm(context.parent) - union_forms = _union_forms(context.parent) - - loaded_children: dict[Path, Any] = {} - - def load_child(f: Any, token: str) -> Any: - """A row's child column (LAK's TAB6 file), loaded from its file, - once per file (SFR's periods may name one table again).""" - path = Path(_strip_quotes(token)) - if path not in loaded_children: - context = attrs.evolve(rows_context, parent=cls) - loaded_children[path] = _load_file_child(f, path, context) - return loaded_children[path] - - # ── Pass 2: block Item-list fields (packagedata, partitions …) ────────── - for block_name, (f, item_cls) in block_item_fields.items(): - block_rows = raw_lower.get(block_name, []) - if not block_rows: - continue - rows = _resolve_open_close_rows(block_rows, context, item_cls, sizes, enabled) - row_list = _parse_rows( - rows, - item_cls, - sizes=sizes, - enabled=enabled, - context=rows_context, - union_arm=union_arm, - union_forms=union_forms, - load_child=load_child, - words=item_list_words(f.type), - ) - if row_list is not None: - init_key = f.alias if (f.alias and not f.alias.startswith("_")) else f.name - kwargs[init_key] = row_list - if (list_io := _list_io(block_rows, row_list, item_cls, rows_context)) is not None: - list_ios[_list_key(f)] = list_io - - # ── Pass 2b: blocks repeating under a record header ────────────────────── - # Read from `raw`, not `raw_lower`: the header keeps its case (a file name). - for block_name, (f, block_cls) in header_block_fields.items(): - header_cls, list_name, item_cls = block_cls.parts() - blocks = [] - for raw_name, rows in raw.items(): - prefix, *header = raw_name.split() - if prefix.lower() != block_name or not header: - continue - rows = _resolve_open_close_rows(rows, context, item_cls, sizes, enabled) - items = _parse_rows( - rows, - item_cls, - sizes=sizes, - enabled=enabled, - context=rows_context, - union_arm=union_arm, - union_forms=union_forms, - ) - blocks.append( - block_cls( - **{block_cls._header: header_cls.from_tokens(header), list_name: items or []} - ) - ) - if blocks: - kwargs[f.alias or f.name] = blocks - - # ── Pass 3: period blocks ──────────────────────────────────────────────── - # At most one fill-forward block per component (enforced by codegen). - kper_rows: dict[int, list] = {} - if fill_forward_blocks: - (fill_forward_block,) = fill_forward_blocks - kper_rows = _group_repeating_rows(raw_lower, fill_forward_blocks, lambda s: int(s) - 1).get( - fill_forward_block, {} - ) - - if kper_rows: - if period_field is not None: - assert period_item_cls is not None # set together with period_field above - spd: dict[int, list | ItemTable] = {} - for kper, block_rows in sorted(kper_rows.items()): - if not block_rows: - # an empty period block turns off every boundary - spd[kper] = [] - continue - rows = _resolve_open_close_rows( - block_rows, context, period_item_cls, sizes, enabled - ) - row_list = _parse_rows( - rows, - period_item_cls, - sizes=sizes, - enabled=enabled, - context=rows_context, - union_arm=union_arm, - union_forms=union_forms, - load_child=load_child, - words=item_list_words(period_field.type), - ) - if row_list is not None: - spd[kper] = row_list - list_io = _list_io(block_rows, row_list, period_item_cls, rows_context) - if list_io is not None: - list_ios[(_list_key(period_field), kper)] = list_io - if spd: - # Use the alias (stress_period_data) as the init kwarg - init_key = period_field.alias if period_field.alias else period_field.name - kwargs[init_key] = spd - - else: - # ── Pass 3b: READARRAY period fields (G/A variants) ───────────── - # Packages like Rcha/Chdg store full-grid arrays per stress period. - # Each field is fill_forward and a dict[int, Int|FloatArrayLike] - # keyed by period -- not an Item-list (else period_field would be - # set above). - ra_fields = { - f.name: f - for f in attrs.fields(cls) - if f.metadata.get("fill_forward") - and f.name not in repeating_array_fields - and to_field_type(f.type) in ("integer", "double") - and f.init is not False - and not f.metadata.get("fk") - } - # Dynamically named arrays (RCHA's aux), one per name in the field the fk - # points at: written under the name, not the field's. - named: dict[str, tuple[Any, str]] = { - str(n).lower(): (f, str(n)) - for f in attrs.fields(cls) - if f.metadata.get("fill_forward") and (fk := f.metadata.get("fk")) - for n in _names(kwargs.get(fk.rsplit(".", 1)[-1])) - } - if ra_fields and dims: - grid = is_grid_package(cls) - - # Each field holds the periods the file gives (see - # flopy4.mf6.period_arrays). An empty grid period block - # clears every boundary: its stress arrays are None. - periods: dict[str, dict[int, np.ndarray | TimeArraySeriesRef | None]] = {} - named_periods: dict[str, dict[int, dict[str, np.ndarray | TimeArraySeriesRef]]] = {} - # An auxiliary name that matches a field's (Q) is the aux - # array, as in MF6. - lookup = ra_fields | {k: f for k, (f, _) in named.items()} - for kper, rows in sorted(kper_rows.items()): - if not rows: - if grid: - for fname in ra_fields: - periods.setdefault(fname, {})[kper] = None - continue - period_ios: dict = {} - parsed = _parse_readarray_period_block(rows, lookup, dims, context, period_ios) - for k, io in period_ios.items(): - name_, *layer = (k,) if isinstance(k, str) else k - if name_ not in named: - array_ios[(name_, kper, *layer)] = io - for key, arr in parsed.items(): - if key in named: - f, aux_name = named[key] - named_periods.setdefault(f.name, {}).setdefault(kper, {})[aux_name] = ( - arr - ) - else: - periods.setdefault(key, {})[kper] = arr - kwargs.update(periods) - kwargs.update(named_periods) - - # ── Pass 3c: array fields whose own block repeats (utl-tas.tas_array is - # the only current DFN example) ────────────────────────────────────────── - # No `layered` form (single flat control record, always) -- confirmed - # every current field of this shape is only ever consumed by - # single-layer array packages (their own array fields are likewise - # ncpl-shaped, no layered form), so the flat length is ncpl, not the - # full-grid nodes count. Same derivation as Pass 3b's READARRAY period - # fields. Row grouping (by "{block} {header}" prefix, cast header value) - # is the same mechanic Pass 3 uses for "period" -- see - # _group_repeating_rows -- just with a no-offset header cast to the - # field's own dict key type instead of period's int/-1 one. - if repeating_array_fields: - effective_dims = dims or _self_dims_from_kwargs(kwargs) - nodes = effective_dims.get("nodes", 0) - if nodes: - nlay = effective_dims.get("nlay", 1) - ncpl = nodes // nlay if nlay > 1 else nodes - for fname, f in repeating_array_fields.items(): - block = f.metadata["block"] - key_type = repeating_array_key_type(f.type) - series_rows = _group_repeating_rows(raw_lower, {block}, key_type).get(block) - if not series_rows: - continue - dtype = np.int64 if to_field_type(f.type) == "integer" else np.float64 - length = _griddata_flat_length(f, effective_dims, ncpl) - series: dict[Any, np.ndarray] = {} - for header, rows in sorted(series_rows.items()): - if not rows: - continue - value, _ = _read_control_record(parts(rows), 0, context, dtype, length, fname) - series[header] = value - if series: - init_key = f.alias if f.alias else fname - kwargs[init_key] = series - - # ── Pass 4: array blocks (griddata, connectiondata) ────────────────────── - # A DimensionProvider (Dis/Disv/Disu) has no external `dims` the first - # time it's loaded -- it *is* the dims source. Its own array blocks still - # need shapes, derived from the DIMENSIONS block Pass 1 already parsed - # into kwargs above. A no-op ({}) for any other class, which just falls - # through to the `dims` param threaded from an already-loaded sibling. - effective_dims = dims or _self_dims_from_kwargs(kwargs) - if effective_dims: - for block_name, block_fields in array_fields.items(): - if rows := raw_lower.get(block_name): - kwargs.update( - _parse_array_block(rows, block_fields, effective_dims, context, array_ios) - ) - - kwargs.update(binding_kwargs) - if name is not None: - kwargs["name"] = name - if array_ios or list_ios: - # write the arrays and lists back the way the file wrote them - kwargs["write_context"] = WriteContext(arrays=array_ios, lists=list_ios) + load = _Load(cls, context) + found = _occurrences(raw, cls) + for block_name in file_blocks(cls): + if block_name in found: + load.read(block_name, found[block_name]) - return cls(**kwargs) + return load.finish(name) diff --git a/flopy4/mf6/exg/chfgwf.py b/flopy4/mf6/exg/chfgwf.py index e9c31d41..8e4f5249 100644 --- a/flopy4/mf6/exg/chfgwf.py +++ b/flopy4/mf6/exg/chfgwf.py @@ -54,6 +54,7 @@ class Exchangedata(Item): exchangedata: Optional[list[Exchangedata]] = list_( default=None, block="exchangedata", + tagged=False, shape=("nexg",), ) diff --git a/flopy4/mf6/exg/gwegwe.py b/flopy4/mf6/exg/gwegwe.py index 0c1b0e7a..82bdabfa 100644 --- a/flopy4/mf6/exg/gwegwe.py +++ b/flopy4/mf6/exg/gwegwe.py @@ -109,6 +109,7 @@ class Exchangedata(Item): exchangedata: Optional[list[Exchangedata]] = list_( default=None, block="exchangedata", + tagged=False, shape=("nexg",), ) diff --git a/flopy4/mf6/exg/gwfgwf.py b/flopy4/mf6/exg/gwfgwf.py index 0ee9c877..8935edfd 100644 --- a/flopy4/mf6/exg/gwfgwf.py +++ b/flopy4/mf6/exg/gwfgwf.py @@ -112,6 +112,7 @@ class Exchangedata(Item): exchangedata: Optional[list[Exchangedata]] = list_( default=None, block="exchangedata", + tagged=False, shape=("nexg",), ) diff --git a/flopy4/mf6/exg/gwtgwt.py b/flopy4/mf6/exg/gwtgwt.py index ed6f6d21..493a52f9 100644 --- a/flopy4/mf6/exg/gwtgwt.py +++ b/flopy4/mf6/exg/gwtgwt.py @@ -109,6 +109,7 @@ class Exchangedata(Item): exchangedata: Optional[list[Exchangedata]] = list_( default=None, block="exchangedata", + tagged=False, shape=("nexg",), ) diff --git a/flopy4/mf6/exg/olfgwf.py b/flopy4/mf6/exg/olfgwf.py index 545985fd..3a173ab3 100644 --- a/flopy4/mf6/exg/olfgwf.py +++ b/flopy4/mf6/exg/olfgwf.py @@ -54,6 +54,7 @@ class Exchangedata(Item): exchangedata: Optional[list[Exchangedata]] = list_( default=None, block="exchangedata", + tagged=False, shape=("nexg",), ) diff --git a/flopy4/mf6/external.py b/flopy4/mf6/external.py index f8c118e2..e06b3da5 100644 --- a/flopy4/mf6/external.py +++ b/flopy4/mf6/external.py @@ -66,6 +66,10 @@ class _Target: binary: bool hash: str | None = None # the values' hash when loaded records: np.ndarray | None = None # a list's rows, for a binary file + # written to a file because `WriteContext.array_format` says to, and + # where to if it can't be `path`, absolute, normalized + forced: bool = False + own: Path | None = None def unchanged(self) -> bool: """Whether the values are as loaded from the file.""" @@ -116,7 +120,9 @@ def write_external_arrays( the writer can't tell which is the edited one, and writes every array of the file inline. An array disagreeing with a file another component already wrote is written inline. Either way, with a - warning. + warning. An array written to a file because the context's + `array_format` says to isn't written inline, but to a file of its + own, named as if it had no path. With `context.strict`, either rule raises `ExternalFileError` instead, before any file of the component is written. @@ -208,25 +214,45 @@ def _write_targets( inline: list[_Target] = [] writes: list[_Target] = [] - for path, group in groups.items(): + queue = list(groups.items()) + + def apart(group: list[_Target]) -> str: + """Write `group`'s arrays inline, or those `array_format` sends to + files to files of their own, and say which, for a warning.""" + alone = [t for t in group if t.forced and t.own is not None] + kept = [t for t in group if not any(t is a for a in alone)] + inline.extend(kept) + for t in alone: + assert t.own is not None + t.path = _unique(t.own, claimed) + claimed.add(t.path) + queue.append((t.path, [t])) + if not alone: + return "writing them inline" + where = ", ".join(f"{t.label} to {t.path.name}" for t in alone) + if not kept: + return f"writing {where}" + return f"writing {where}, and {', '.join(t.label for t in kept)} inline" + + while queue: + path, group = queue.pop(0) if (differ := _disagree(group)) is not None: unchanged = [t for t in group if t.unchanged()] changed = [t for t in group if not any(t is u for u in unchanged)] if unchanged and changed and _disagree(unchanged) is None: warn( f"{path}: {', '.join(t.label for t in changed)} changed since " - "loaded from this file; writing them inline. " + f"loaded from this file; {apart(changed)}. " f"{', '.join(t.label for t in unchanged)} still use it." ) - inline.extend(changed) group = unchanged else: + labels = ", ".join(t.label for t in group) warn( - f"{path}: {', '.join(t.label for t in group)} use this file but " - f"{differ}; writing them inline. To write one of them to the " - "file, give the others another path." + f"{path}: {labels} use this file but {differ}; {apart(group)}. " + "To write one of them to the file, give the others another " + "ArrayIO path." ) - inline.extend(group) continue first = group[0] if (written := files.get(path)) is not None: @@ -238,9 +264,8 @@ def _write_targets( if differ: warn( f"{path}: {', '.join(t.label for t in group)} use this file, " - f"which {written.label} wrote {differ}; writing them inline." + f"which {written.label} wrote {differ}; {apart(group)}." ) - inline.extend(group) continue writes.append(first) @@ -307,19 +332,29 @@ def _targets( def target(layer: int | None) -> _Target | None: values = value if layer is None else value.isel(nlay=layer) if layer is None: - own, path, loaded = (value.attrs.get(a) for a in ("format", "path", "hash")) + own_format, path, loaded = (value.attrs.get(a) for a in ("format", "path", "hash")) else: - own = layer_format.get(layer, value.attrs.get("format")) + own_format = layer_format.get(layer, value.attrs.get("format")) path, loaded = layer_path.get(layer), layer_hash.get(layer) - fmt = _file_format(values, own, path is not None, context) + fmt = _file_format(values, own_format, path is not None, context) if fmt is None: return None binary = fmt == "binary" - if path is None: - name = stem + ("" if layer is None else f"_l{layer + 1}") - path = filename.parent / f"{name}.{'bin' if binary else 'txt'}" + name = stem + ("" if layer is None else f"_l{layer + 1}") + own = _absolute(filename.parent / f"{name}.{'bin' if binary else 'txt'}", root) what = where if layer is None else f"{where} layer {layer + 1}" - return _Target(block_name, key, layer, what, _absolute(path, root), values, binary, loaded) + return _Target( + block_name, + key, + layer, + what, + own if path is None else _absolute(path, root), + values, + binary, + loaded, + forced=own_format is None and fmt == context.array_format, + own=own, + ) by_layer = "nlay" in value.dims and ( bool(layer_path) diff --git a/flopy4/mf6/gwe/ctp.py b/flopy4/mf6/gwe/ctp.py index fe88d5c0..d8b9e589 100644 --- a/flopy4/mf6/gwe/ctp.py +++ b/flopy4/mf6/gwe/ctp.py @@ -8,7 +8,7 @@ from flopy4.mf6._types import TimeSeriesRef, to_array from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, child, double, keyword, list_, string from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -20,6 +20,10 @@ class Ctp(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "ctp": (("cellid",), ("string",)), } @@ -85,6 +89,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) @property diff --git a/flopy4/mf6/gwe/disu.py b/flopy4/mf6/gwe/disu.py index 53c9d171..d3d3c9df 100644 --- a/flopy4/mf6/gwe/disu.py +++ b/flopy4/mf6/gwe/disu.py @@ -172,11 +172,13 @@ class Cell2d(Item): vertices: Optional[list[Vertices]] = list_( default=None, block="vertices", + tagged=False, shape=("nvert",), ) cell2d: Optional[list[Cell2d]] = list_( default=None, block="cell2d", + tagged=False, shape=("nodes",), ) diff --git a/flopy4/mf6/gwe/disv.py b/flopy4/mf6/gwe/disv.py index 67a300ea..9c7c406e 100644 --- a/flopy4/mf6/gwe/disv.py +++ b/flopy4/mf6/gwe/disv.py @@ -134,11 +134,13 @@ class Cell2d(Item): vertices: Optional[list[Vertices]] = list_( default=None, block="vertices", + tagged=False, shape=("nvert",), ) cell2d: Optional[list[Cell2d]] = list_( default=None, block="cell2d", + tagged=False, shape=("ncpl",), ) diff --git a/flopy4/mf6/gwe/esl.py b/flopy4/mf6/gwe/esl.py index 0048dba2..a58ab335 100644 --- a/flopy4/mf6/gwe/esl.py +++ b/flopy4/mf6/gwe/esl.py @@ -8,7 +8,7 @@ from flopy4.mf6._types import TimeSeriesRef, to_array from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, child, double, keyword, list_, string from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -20,6 +20,10 @@ class Esl(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "esl": (("cellid",), ("string",)), "to-mvr": (("cellid",), ("string",)), @@ -86,6 +90,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) @property diff --git a/flopy4/mf6/gwe/fmi.py b/flopy4/mf6/gwe/fmi.py index 975ca22e..89bbdebe 100644 --- a/flopy4/mf6/gwe/fmi.py +++ b/flopy4/mf6/gwe/fmi.py @@ -34,6 +34,7 @@ class Packagedata(Item): packagedata: Optional[list[Packagedata]] = list_( default=None, block="packagedata", + tagged=False, ) diff --git a/flopy4/mf6/gwe/lke.py b/flopy4/mf6/gwe/lke.py index 557ad810..bfe0341e 100644 --- a/flopy4/mf6/gwe/lke.py +++ b/flopy4/mf6/gwe/lke.py @@ -10,7 +10,18 @@ from flopy4.mf6.item import Item from flopy4.mf6.legacy import Legacy from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, child, double, file, integer, keyword, list_, string, union +from flopy4.mf6.spec import ( + Header, + array, + child, + double, + file, + integer, + keyword, + list_, + string, + union, +) from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -22,6 +33,10 @@ class Lke(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "constant": (("index",), ("string",)), "evaporation": (("index",), ("string",)), @@ -175,6 +190,7 @@ class StressPeriodData(Item): packagedata: Optional[list[Packagedata]] = list_( default=None, block="packagedata", + tagged=False, write_if_empty=True, ) _stress_period_data: Optional[dict[int, list[StressPeriodData]]] = list_( @@ -183,6 +199,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) diff --git a/flopy4/mf6/gwe/mwe.py b/flopy4/mf6/gwe/mwe.py index c0589f1a..8ff39d89 100644 --- a/flopy4/mf6/gwe/mwe.py +++ b/flopy4/mf6/gwe/mwe.py @@ -10,7 +10,18 @@ from flopy4.mf6.item import Item from flopy4.mf6.legacy import Legacy from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, child, double, file, integer, keyword, list_, string, union +from flopy4.mf6.spec import ( + Header, + array, + child, + double, + file, + integer, + keyword, + list_, + string, + union, +) from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -22,6 +33,10 @@ class Mwe(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "constant": (("index",), ("string",)), "from-mvr": (("index",), ("string",)), @@ -156,6 +171,7 @@ class StressPeriodData(Item): packagedata: Optional[list[Packagedata]] = list_( default=None, block="packagedata", + tagged=False, write_if_empty=True, ) _stress_period_data: Optional[dict[int, list[StressPeriodData]]] = list_( @@ -164,6 +180,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) diff --git a/flopy4/mf6/gwe/oc.py b/flopy4/mf6/gwe/oc.py index f70e0fac..79d54f2d 100644 --- a/flopy4/mf6/gwe/oc.py +++ b/flopy4/mf6/gwe/oc.py @@ -8,7 +8,7 @@ from flopy4.mf6.legacy import Legacy, oc_period_data from flopy4.mf6.package import Package from flopy4.mf6.record import Record -from flopy4.mf6.spec import array, file, integer, list_, record, string, union +from flopy4.mf6.spec import Header, array, file, integer, list_, record, string, union @attrs.define(kw_only=True, slots=False) @@ -16,6 +16,10 @@ class Oc(Package): dfn_name: ClassVar[str] = "gwe-oc" ftype: ClassVar[str] = "OC6" + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + legacy_kwargs: ClassVar[dict[str, Legacy]] = { "saverecord": Legacy("stress_period_data", oc_period_data), "printrecord": Legacy("stress_period_data", oc_period_data), diff --git a/flopy4/mf6/gwe/sfe.py b/flopy4/mf6/gwe/sfe.py index b2656161..c72ec8d7 100644 --- a/flopy4/mf6/gwe/sfe.py +++ b/flopy4/mf6/gwe/sfe.py @@ -10,7 +10,18 @@ from flopy4.mf6.item import Item from flopy4.mf6.legacy import Legacy from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, child, double, file, integer, keyword, list_, string, union +from flopy4.mf6.spec import ( + Header, + array, + child, + double, + file, + integer, + keyword, + list_, + string, + union, +) from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -22,6 +33,10 @@ class Sfe(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "constant": (("index",), ("string",)), "evaporation": (("index",), ("string",)), @@ -175,6 +190,7 @@ class StressPeriodData(Item): packagedata: Optional[list[Packagedata]] = list_( default=None, block="packagedata", + tagged=False, write_if_empty=True, ) _stress_period_data: Optional[dict[int, list[StressPeriodData]]] = list_( @@ -183,6 +199,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) diff --git a/flopy4/mf6/gwe/ssm.py b/flopy4/mf6/gwe/ssm.py index b37f76c4..b801e83a 100644 --- a/flopy4/mf6/gwe/ssm.py +++ b/flopy4/mf6/gwe/ssm.py @@ -49,11 +49,13 @@ class Fileinput(Item): sources: Optional[list[Sources]] = list_( default=None, block="sources", + tagged=False, write_if_empty=True, ) fileinput: Optional[list[Fileinput]] = list_( default=None, block="fileinput", + tagged=False, ) diff --git a/flopy4/mf6/gwe/uze.py b/flopy4/mf6/gwe/uze.py index f0d37a23..3fe7700e 100644 --- a/flopy4/mf6/gwe/uze.py +++ b/flopy4/mf6/gwe/uze.py @@ -10,7 +10,18 @@ from flopy4.mf6.item import Item from flopy4.mf6.legacy import Legacy from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, child, double, file, integer, keyword, list_, string, union +from flopy4.mf6.spec import ( + Header, + array, + child, + double, + file, + integer, + keyword, + list_, + string, + union, +) from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -22,6 +33,10 @@ class Uze(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "constant": (("index",), ("string",)), "flow-ja-face": (("index", "index"), ("string",)), @@ -163,6 +178,7 @@ class StressPeriodData(Item): packagedata: Optional[list[Packagedata]] = list_( default=None, block="packagedata", + tagged=False, write_if_empty=True, ) _stress_period_data: Optional[dict[int, list[StressPeriodData]]] = list_( @@ -171,6 +187,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) diff --git a/flopy4/mf6/gwf/buy.py b/flopy4/mf6/gwf/buy.py index 67578de7..39aea757 100644 --- a/flopy4/mf6/gwf/buy.py +++ b/flopy4/mf6/gwf/buy.py @@ -50,6 +50,7 @@ class Packagedata(Item): packagedata: Optional[list[Packagedata]] = list_( default=None, block="packagedata", + tagged=False, shape=("nrhospecies",), ) diff --git a/flopy4/mf6/gwf/chd.py b/flopy4/mf6/gwf/chd.py index 55599ea1..317cb269 100644 --- a/flopy4/mf6/gwf/chd.py +++ b/flopy4/mf6/gwf/chd.py @@ -8,7 +8,7 @@ from flopy4.mf6._types import TimeSeriesRef, to_array from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, child, double, keyword, list_, string from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -20,6 +20,10 @@ class Chd(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "chd": (("cellid",), ("string",)), } @@ -85,6 +89,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) @property diff --git a/flopy4/mf6/gwf/chdg.py b/flopy4/mf6/gwf/chdg.py index 5c15a690..10c43d9c 100644 --- a/flopy4/mf6/gwf/chdg.py +++ b/flopy4/mf6/gwf/chdg.py @@ -7,7 +7,7 @@ from flopy4.mf6._types import FloatArrayLike, to_array from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, child, integer, keyword, string +from flopy4.mf6.spec import Header, array, child, integer, keyword, string from flopy4.mf6.utl.obs import Obs @@ -18,6 +18,10 @@ class Chdg(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "chd": (("cellid",), ("string",)), } diff --git a/flopy4/mf6/gwf/csub.py b/flopy4/mf6/gwf/csub.py index c9a3eeaa..87e16ede 100644 --- a/flopy4/mf6/gwf/csub.py +++ b/flopy4/mf6/gwf/csub.py @@ -7,7 +7,18 @@ from flopy4.mf6._types import FloatArrayLike, TimeSeriesRef from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, file, integer, keyword, list_, string +from flopy4.mf6.spec import ( + Header, + array, + cellid_, + child, + double, + file, + integer, + keyword, + list_, + string, +) from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -17,6 +28,10 @@ class Csub(Package): dfn_name: ClassVar[str] = "gwf-csub" ftype: ClassVar[str] = "CSUB6" + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "coarse-compaction": (("cellid",),), "coarse-csub": (("cellid",),), @@ -309,6 +324,7 @@ class StressPeriodData(Item): packagedata: Optional[list[Packagedata]] = list_( default=None, block="packagedata", + tagged=False, shape=("ninterbeds",), ) _stress_period_data: Optional[dict[int, list[StressPeriodData]]] = list_( @@ -317,6 +333,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, shape=("<=maxsig0",), ) diff --git a/flopy4/mf6/gwf/disu.py b/flopy4/mf6/gwf/disu.py index fa5c7302..2724be69 100644 --- a/flopy4/mf6/gwf/disu.py +++ b/flopy4/mf6/gwf/disu.py @@ -172,11 +172,13 @@ class Cell2d(Item): vertices: Optional[list[Vertices]] = list_( default=None, block="vertices", + tagged=False, shape=("nvert",), ) cell2d: Optional[list[Cell2d]] = list_( default=None, block="cell2d", + tagged=False, shape=("nodes",), ) diff --git a/flopy4/mf6/gwf/disv.py b/flopy4/mf6/gwf/disv.py index 136f3e2e..58eaa3ea 100644 --- a/flopy4/mf6/gwf/disv.py +++ b/flopy4/mf6/gwf/disv.py @@ -134,11 +134,13 @@ class Cell2d(Item): vertices: Optional[list[Vertices]] = list_( default=None, block="vertices", + tagged=False, shape=("nvert",), ) cell2d: Optional[list[Cell2d]] = list_( default=None, block="cell2d", + tagged=False, shape=("ncpl",), ) diff --git a/flopy4/mf6/gwf/drn.py b/flopy4/mf6/gwf/drn.py index e81736b9..c94a463a 100644 --- a/flopy4/mf6/gwf/drn.py +++ b/flopy4/mf6/gwf/drn.py @@ -8,7 +8,7 @@ from flopy4.mf6._types import TimeSeriesRef, to_array from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, child, double, keyword, list_, string from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -20,6 +20,10 @@ class Drn(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "drn": (("cellid",), ("string",)), "to-mvr": (("cellid",), ("string",)), @@ -102,6 +106,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) @property diff --git a/flopy4/mf6/gwf/drng.py b/flopy4/mf6/gwf/drng.py index 9bd607e5..8b02629f 100644 --- a/flopy4/mf6/gwf/drng.py +++ b/flopy4/mf6/gwf/drng.py @@ -7,7 +7,7 @@ from flopy4.mf6._types import FloatArrayLike, to_array from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, child, integer, keyword, string +from flopy4.mf6.spec import Header, array, child, integer, keyword, string from flopy4.mf6.utl.obs import Obs @@ -18,6 +18,10 @@ class Drng(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "drn": (("cellid",), ("string",)), "to-mvr": (("cellid",), ("string",)), diff --git a/flopy4/mf6/gwf/evt.py b/flopy4/mf6/gwf/evt.py index 57f53fb3..b866f121 100644 --- a/flopy4/mf6/gwf/evt.py +++ b/flopy4/mf6/gwf/evt.py @@ -8,7 +8,7 @@ from flopy4.mf6._types import TimeSeriesRef, to_array from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, integer, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, child, double, integer, keyword, list_, string from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -20,6 +20,10 @@ class Evt(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "evt": (("cellid",), ("string",)), } @@ -113,6 +117,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) @property diff --git a/flopy4/mf6/gwf/evta.py b/flopy4/mf6/gwf/evta.py index a941f810..8247df59 100644 --- a/flopy4/mf6/gwf/evta.py +++ b/flopy4/mf6/gwf/evta.py @@ -7,7 +7,7 @@ from flopy4.mf6._types import FloatArrayLike, IntArrayLike, TimeArraySeriesRef, to_array from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, child, keyword, string +from flopy4.mf6.spec import Header, array, child, keyword, string from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.tas import Tas @@ -19,6 +19,10 @@ class Evta(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "evt": (("cellid",), ("string",)), } diff --git a/flopy4/mf6/gwf/ghb.py b/flopy4/mf6/gwf/ghb.py index e1677ac7..4e514433 100644 --- a/flopy4/mf6/gwf/ghb.py +++ b/flopy4/mf6/gwf/ghb.py @@ -8,7 +8,7 @@ from flopy4.mf6._types import TimeSeriesRef, to_array from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, child, double, keyword, list_, string from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -20,6 +20,10 @@ class Ghb(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "ghb": (("cellid",), ("string",)), "to-mvr": (("cellid",), ("string",)), @@ -96,6 +100,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) @property diff --git a/flopy4/mf6/gwf/ghbg.py b/flopy4/mf6/gwf/ghbg.py index 6e37617b..722edfd6 100644 --- a/flopy4/mf6/gwf/ghbg.py +++ b/flopy4/mf6/gwf/ghbg.py @@ -7,7 +7,7 @@ from flopy4.mf6._types import FloatArrayLike, to_array from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, child, integer, keyword, string +from flopy4.mf6.spec import Header, array, child, integer, keyword, string from flopy4.mf6.utl.obs import Obs @@ -18,6 +18,10 @@ class Ghbg(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "ghb": (("cellid",), ("string",)), "to-mvr": (("cellid",), ("string",)), diff --git a/flopy4/mf6/gwf/gnc.py b/flopy4/mf6/gwf/gnc.py index c1470529..7df80c41 100644 --- a/flopy4/mf6/gwf/gnc.py +++ b/flopy4/mf6/gwf/gnc.py @@ -53,6 +53,7 @@ class Gncdata(Item): gncdata: Optional[list[Gncdata]] = list_( default=None, block="gncdata", + tagged=False, shape=("numgnc",), ) diff --git a/flopy4/mf6/gwf/hfb.py b/flopy4/mf6/gwf/hfb.py index 6b9efd83..e9ca4ec4 100644 --- a/flopy4/mf6/gwf/hfb.py +++ b/flopy4/mf6/gwf/hfb.py @@ -5,7 +5,7 @@ from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import cellid_, double, integer, keyword, list_ +from flopy4.mf6.spec import Header, cellid_, double, integer, keyword, list_ @attrs.define(kw_only=True, slots=False) @@ -13,6 +13,10 @@ class Hfb(Package): dfn_name: ClassVar[str] = "gwf-hfb" ftype: ClassVar[str] = "HFB6" + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + @attrs.define class StressPeriodData(Item): cellid1: tuple[int, ...] = cellid_() @@ -36,6 +40,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, shape=("<=maxhfb",), ) diff --git a/flopy4/mf6/gwf/lak.py b/flopy4/mf6/gwf/lak.py index 442748a4..ecc44e09 100644 --- a/flopy4/mf6/gwf/lak.py +++ b/flopy4/mf6/gwf/lak.py @@ -12,6 +12,7 @@ from flopy4.mf6.legacy import Legacy from flopy4.mf6.package import Package from flopy4.mf6.spec import ( + Header, array, cellid_, child, @@ -35,6 +36,10 @@ class Lak(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "conductance": (("index", "index"), ("index", "string"), ("string",)), "constant": (("index",), ("string",)), @@ -337,21 +342,25 @@ class Auxiliary(Item): packagedata: Optional[list[Packagedata]] = list_( default=None, block="packagedata", + tagged=False, shape=("nlakes",), ) connectiondata: Optional[list[Connectiondata]] = list_( default=None, block="connectiondata", + tagged=False, write_if_empty=True, ) tables: Optional[list[Tables]] = list_( default=None, block="tables", + tagged=False, shape=("ntables",), ) outlets: Optional[list[Outlets]] = list_( default=None, block="outlets", + tagged=False, shape=("noutlets",), ) _stress_period_data: Optional[dict[int, list[_StressPeriodDataItem]]] = list_( @@ -360,6 +369,7 @@ class Auxiliary(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) nlakeconn = DerivedDim("sum(packagedata.nlakeconn)") diff --git a/flopy4/mf6/gwf/maw.py b/flopy4/mf6/gwf/maw.py index ddcdde91..f62731b5 100644 --- a/flopy4/mf6/gwf/maw.py +++ b/flopy4/mf6/gwf/maw.py @@ -12,6 +12,7 @@ from flopy4.mf6.legacy import Legacy from flopy4.mf6.package import Package from flopy4.mf6.spec import ( + Header, array, cellid_, child, @@ -34,6 +35,10 @@ class Maw(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "conductance": (("index", "index"), ("index", "string"), ("string",)), "constant": (("index",), ("string",)), @@ -276,16 +281,19 @@ class StressPeriodData(Item): packagedata: Optional[list[Packagedata]] = list_( default=None, block="packagedata", + tagged=False, shape=("nmawwells",), ) connectiondata: Optional[list[Connectiondata]] = list_( default=None, block="connectiondata", + tagged=False, write_if_empty=True, ) angledata: Optional[list[Angledata]] = list_( default=None, block="angledata", + tagged=False, ) _stress_period_data: Optional[dict[int, list[StressPeriodData]]] = list_( alias="stress_period_data", @@ -293,6 +301,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) ngwfnodes = DerivedDim("sum(packagedata.ngwfnodes)") diff --git a/flopy4/mf6/gwf/mvr.py b/flopy4/mf6/gwf/mvr.py index 514348e9..9f9a8413 100644 --- a/flopy4/mf6/gwf/mvr.py +++ b/flopy4/mf6/gwf/mvr.py @@ -7,7 +7,7 @@ from flopy4.mf6.item import Item from flopy4.mf6.legacy import Legacy from flopy4.mf6.package import Package -from flopy4.mf6.spec import double, file, integer, keyword, list_, string +from flopy4.mf6.spec import Header, double, file, integer, keyword, list_, string @attrs.define(kw_only=True, slots=False) @@ -15,6 +15,10 @@ class Mvr(Package): dfn_name: ClassVar[str] = "gwf-mvr" ftype: ClassVar[str] = "MVR6" + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + legacy_kwargs: ClassVar[dict[str, Legacy]] = { "perioddata": Legacy("stress_period_data"), } @@ -104,6 +108,7 @@ class StressPeriodData(Item): packages: Optional[list[Packages]] = list_( default=None, block="packages", + tagged=False, shape=("maxpackages",), ) _stress_period_data: Optional[dict[int, list[StressPeriodData]]] = list_( @@ -112,6 +117,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) diff --git a/flopy4/mf6/gwf/oc.py b/flopy4/mf6/gwf/oc.py index bbcd1b26..42b81695 100644 --- a/flopy4/mf6/gwf/oc.py +++ b/flopy4/mf6/gwf/oc.py @@ -8,7 +8,7 @@ from flopy4.mf6.legacy import Legacy, oc_period_data from flopy4.mf6.package import Package from flopy4.mf6.record import Record -from flopy4.mf6.spec import array, file, integer, list_, record, string, union +from flopy4.mf6.spec import Header, array, file, integer, list_, record, string, union @attrs.define(kw_only=True, slots=False) @@ -16,6 +16,10 @@ class Oc(Package): dfn_name: ClassVar[str] = "gwf-oc" ftype: ClassVar[str] = "OC6" + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + legacy_kwargs: ClassVar[dict[str, Legacy]] = { "saverecord": Legacy("stress_period_data", oc_period_data), "printrecord": Legacy("stress_period_data", oc_period_data), diff --git a/flopy4/mf6/gwf/rch.py b/flopy4/mf6/gwf/rch.py index 252df7ce..8e088050 100644 --- a/flopy4/mf6/gwf/rch.py +++ b/flopy4/mf6/gwf/rch.py @@ -8,7 +8,7 @@ from flopy4.mf6._types import TimeSeriesRef, to_array from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, child, double, keyword, list_, string from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -20,6 +20,10 @@ class Rch(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "rch": (("cellid",), ("string",)), } @@ -91,6 +95,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) @property diff --git a/flopy4/mf6/gwf/rcha.py b/flopy4/mf6/gwf/rcha.py index 6e4cf189..d563a456 100644 --- a/flopy4/mf6/gwf/rcha.py +++ b/flopy4/mf6/gwf/rcha.py @@ -7,7 +7,7 @@ from flopy4.mf6._types import FloatArrayLike, IntArrayLike, TimeArraySeriesRef, to_array from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, child, keyword, string +from flopy4.mf6.spec import Header, array, child, keyword, string from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.tas import Tas @@ -19,6 +19,10 @@ class Rcha(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "rch": (("cellid",), ("string",)), } diff --git a/flopy4/mf6/gwf/riv.py b/flopy4/mf6/gwf/riv.py index 0332ec13..1cc6417c 100644 --- a/flopy4/mf6/gwf/riv.py +++ b/flopy4/mf6/gwf/riv.py @@ -8,7 +8,7 @@ from flopy4.mf6._types import TimeSeriesRef, to_array from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, child, double, keyword, list_, string from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -20,6 +20,10 @@ class Riv(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "riv": (("cellid",), ("string",)), "to-mvr": (("cellid",), ("string",)), @@ -97,6 +101,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) @property diff --git a/flopy4/mf6/gwf/rivg.py b/flopy4/mf6/gwf/rivg.py index a452a72e..deb83d7c 100644 --- a/flopy4/mf6/gwf/rivg.py +++ b/flopy4/mf6/gwf/rivg.py @@ -7,7 +7,7 @@ from flopy4.mf6._types import FloatArrayLike, to_array from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, child, integer, keyword, string +from flopy4.mf6.spec import Header, array, child, integer, keyword, string from flopy4.mf6.utl.obs import Obs @@ -18,6 +18,10 @@ class Rivg(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "riv": (("cellid",), ("string",)), "to-mvr": (("cellid",), ("string",)), diff --git a/flopy4/mf6/gwf/sfr.py b/flopy4/mf6/gwf/sfr.py index 4bd4df2d..d0c41639 100644 --- a/flopy4/mf6/gwf/sfr.py +++ b/flopy4/mf6/gwf/sfr.py @@ -11,6 +11,7 @@ from flopy4.mf6.legacy import Legacy from flopy4.mf6.package import Package from flopy4.mf6.spec import ( + Header, array, cellid_, child, @@ -34,6 +35,10 @@ class Sfr(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "depth": (("index",), ("string",)), "downstream-flow": (("index",), ("string",)), @@ -317,24 +322,29 @@ class StressPeriodData(Item): packagedata: Optional[list[Packagedata]] = list_( default=None, block="packagedata", + tagged=False, shape=("nreaches",), ) crosssections: Optional[list[Crosssections]] = list_( default=None, block="crosssections", + tagged=False, ) connectiondata: Optional[list[Connectiondata]] = list_( default=None, block="connectiondata", + tagged=False, shape=("nreaches",), ) diversions: Optional[list[Diversions]] = list_( default=None, block="diversions", + tagged=False, ) initialstages: Optional[list[Initialstages]] = list_( default=None, block="initialstages", + tagged=False, shape=("nreaches",), ) _stress_period_data: Optional[dict[int, list[StressPeriodData]]] = list_( @@ -343,6 +353,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) diff --git a/flopy4/mf6/gwf/sto.py b/flopy4/mf6/gwf/sto.py index 3abde14d..a833b84d 100644 --- a/flopy4/mf6/gwf/sto.py +++ b/flopy4/mf6/gwf/sto.py @@ -1,13 +1,12 @@ # autogenerated file, do not modify -from typing import ClassVar, Optional +from typing import ClassVar, Literal, Optional import attrs from flopy4.mf6._types import FloatArrayLike, IntArrayLike -from flopy4.mf6.item import Item from flopy4.mf6.legacy import Legacy, sto_period_data from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, child, keyword, list_, string +from flopy4.mf6.spec import Header, array, child, keyword, string from flopy4.mf6.utl.tvs import Tvs @@ -16,15 +15,15 @@ class Sto(Package): dfn_name: ClassVar[str] = "gwf-sto" ftype: ClassVar[str] = "STO6" + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + legacy_kwargs: ClassVar[dict[str, Legacy]] = { "steady_state": Legacy("stress_period_data", sto_period_data), "transient": Legacy("stress_period_data", sto_period_data), } - @attrs.define - class StressPeriodData(Item): - stress_period_data: str = string() - save_flows: bool = keyword( default=False, block="options", @@ -80,13 +79,10 @@ class StressPeriodData(Item): netcdf=True, longname="specific yield", ) # type: ignore[assignment] - _stress_period_data: Optional[dict[int, list[StressPeriodData]]] = list_( - alias="stress_period_data", + stress_period_data: Optional[dict[int, Literal["steady-state", "transient"]]] = string( default=None, - repr=False, block="period", fill_forward=True, + valid=("steady-state", "transient"), + tagged=False, ) - - -StoStressPeriodData = Sto.StressPeriodData diff --git a/flopy4/mf6/gwf/uzf.py b/flopy4/mf6/gwf/uzf.py index d61ca5ec..7b5f2a5f 100644 --- a/flopy4/mf6/gwf/uzf.py +++ b/flopy4/mf6/gwf/uzf.py @@ -10,7 +10,18 @@ from flopy4.mf6.item import Item from flopy4.mf6.legacy import Legacy from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, file, integer, keyword, list_, string +from flopy4.mf6.spec import ( + Header, + array, + cellid_, + child, + double, + file, + integer, + keyword, + list_, + string, +) from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -22,6 +33,10 @@ class Uzf(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "from-mvr": (("index",), ("string",)), "infiltration": (("index",), ("string",)), @@ -211,6 +226,7 @@ class StressPeriodData(Item): packagedata: Optional[list[Packagedata]] = list_( default=None, block="packagedata", + tagged=False, shape=("nuzfcells",), ) _stress_period_data: Optional[dict[int, list[StressPeriodData]]] = list_( @@ -219,6 +235,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) diff --git a/flopy4/mf6/gwf/vsc.py b/flopy4/mf6/gwf/vsc.py index f56caa41..853a84af 100644 --- a/flopy4/mf6/gwf/vsc.py +++ b/flopy4/mf6/gwf/vsc.py @@ -74,6 +74,7 @@ class Packagedata(Item): packagedata: Optional[list[Packagedata]] = list_( default=None, block="packagedata", + tagged=False, shape=("nviscspecies",), ) diff --git a/flopy4/mf6/gwf/wel.py b/flopy4/mf6/gwf/wel.py index 9a07f4f3..89504acd 100644 --- a/flopy4/mf6/gwf/wel.py +++ b/flopy4/mf6/gwf/wel.py @@ -9,7 +9,7 @@ from flopy4.mf6._types import TimeSeriesRef, to_array from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, file, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, child, double, file, keyword, list_, string from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -21,6 +21,10 @@ class Wel(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "to-mvr": (("cellid",), ("string",)), "wel": (("cellid",), ("string",)), @@ -123,6 +127,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) @property diff --git a/flopy4/mf6/gwf/welg.py b/flopy4/mf6/gwf/welg.py index 5dd9ab3c..8aa0d4e1 100644 --- a/flopy4/mf6/gwf/welg.py +++ b/flopy4/mf6/gwf/welg.py @@ -8,7 +8,7 @@ from flopy4.mf6._types import FloatArrayLike, to_array from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, child, double, file, integer, keyword, string +from flopy4.mf6.spec import Header, array, child, double, file, integer, keyword, string from flopy4.mf6.utl.obs import Obs @@ -19,6 +19,10 @@ class Welg(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "to-mvr": (("cellid",), ("string",)), "wel": (("cellid",), ("string",)), diff --git a/flopy4/mf6/gwt/cnc.py b/flopy4/mf6/gwt/cnc.py index 38cca99e..a718263a 100644 --- a/flopy4/mf6/gwt/cnc.py +++ b/flopy4/mf6/gwt/cnc.py @@ -8,7 +8,7 @@ from flopy4.mf6._types import TimeSeriesRef, to_array from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, child, double, keyword, list_, string from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -20,6 +20,10 @@ class Cnc(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "cnc": (("cellid",), ("string",)), } @@ -85,6 +89,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) @property diff --git a/flopy4/mf6/gwt/disu.py b/flopy4/mf6/gwt/disu.py index 2040f19c..8dd515a4 100644 --- a/flopy4/mf6/gwt/disu.py +++ b/flopy4/mf6/gwt/disu.py @@ -172,11 +172,13 @@ class Cell2d(Item): vertices: Optional[list[Vertices]] = list_( default=None, block="vertices", + tagged=False, shape=("nvert",), ) cell2d: Optional[list[Cell2d]] = list_( default=None, block="cell2d", + tagged=False, shape=("nodes",), ) diff --git a/flopy4/mf6/gwt/disv.py b/flopy4/mf6/gwt/disv.py index 44d9a86b..87033ba5 100644 --- a/flopy4/mf6/gwt/disv.py +++ b/flopy4/mf6/gwt/disv.py @@ -134,11 +134,13 @@ class Cell2d(Item): vertices: Optional[list[Vertices]] = list_( default=None, block="vertices", + tagged=False, shape=("nvert",), ) cell2d: Optional[list[Cell2d]] = list_( default=None, block="cell2d", + tagged=False, shape=("ncpl",), ) diff --git a/flopy4/mf6/gwt/fmi.py b/flopy4/mf6/gwt/fmi.py index a35e960e..39db0e01 100644 --- a/flopy4/mf6/gwt/fmi.py +++ b/flopy4/mf6/gwt/fmi.py @@ -34,6 +34,7 @@ class Packagedata(Item): packagedata: Optional[list[Packagedata]] = list_( default=None, block="packagedata", + tagged=False, ) diff --git a/flopy4/mf6/gwt/lkt.py b/flopy4/mf6/gwt/lkt.py index 520bad9d..25500343 100644 --- a/flopy4/mf6/gwt/lkt.py +++ b/flopy4/mf6/gwt/lkt.py @@ -10,7 +10,18 @@ from flopy4.mf6.item import Item from flopy4.mf6.legacy import Legacy from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, child, double, file, integer, keyword, list_, string, union +from flopy4.mf6.spec import ( + Header, + array, + child, + double, + file, + integer, + keyword, + list_, + string, + union, +) from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -22,6 +33,10 @@ class Lkt(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "concentration": (("index",), ("string",)), "constant": (("index",), ("string",)), @@ -173,6 +188,7 @@ class StressPeriodData(Item): packagedata: Optional[list[Packagedata]] = list_( default=None, block="packagedata", + tagged=False, write_if_empty=True, ) _stress_period_data: Optional[dict[int, list[StressPeriodData]]] = list_( @@ -181,6 +197,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) diff --git a/flopy4/mf6/gwt/mwt.py b/flopy4/mf6/gwt/mwt.py index b4315f5b..c1cdabc0 100644 --- a/flopy4/mf6/gwt/mwt.py +++ b/flopy4/mf6/gwt/mwt.py @@ -10,7 +10,18 @@ from flopy4.mf6.item import Item from flopy4.mf6.legacy import Legacy from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, child, double, file, integer, keyword, list_, string, union +from flopy4.mf6.spec import ( + Header, + array, + child, + double, + file, + integer, + keyword, + list_, + string, + union, +) from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -22,6 +33,10 @@ class Mwt(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "concentration": (("index",), ("string",)), "constant": (("index",), ("string",)), @@ -154,6 +169,7 @@ class StressPeriodData(Item): packagedata: Optional[list[Packagedata]] = list_( default=None, block="packagedata", + tagged=False, write_if_empty=True, ) _stress_period_data: Optional[dict[int, list[StressPeriodData]]] = list_( @@ -162,6 +178,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) diff --git a/flopy4/mf6/gwt/oc.py b/flopy4/mf6/gwt/oc.py index 59c06905..c1d27188 100644 --- a/flopy4/mf6/gwt/oc.py +++ b/flopy4/mf6/gwt/oc.py @@ -8,7 +8,7 @@ from flopy4.mf6.legacy import Legacy, oc_period_data from flopy4.mf6.package import Package from flopy4.mf6.record import Record -from flopy4.mf6.spec import array, file, integer, list_, record, string, union +from flopy4.mf6.spec import Header, array, file, integer, list_, record, string, union @attrs.define(kw_only=True, slots=False) @@ -16,6 +16,10 @@ class Oc(Package): dfn_name: ClassVar[str] = "gwt-oc" ftype: ClassVar[str] = "OC6" + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + legacy_kwargs: ClassVar[dict[str, Legacy]] = { "saverecord": Legacy("stress_period_data", oc_period_data), "printrecord": Legacy("stress_period_data", oc_period_data), diff --git a/flopy4/mf6/gwt/sft.py b/flopy4/mf6/gwt/sft.py index 9defcb46..fc24538f 100644 --- a/flopy4/mf6/gwt/sft.py +++ b/flopy4/mf6/gwt/sft.py @@ -10,7 +10,18 @@ from flopy4.mf6.item import Item from flopy4.mf6.legacy import Legacy from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, child, double, file, integer, keyword, list_, string, union +from flopy4.mf6.spec import ( + Header, + array, + child, + double, + file, + integer, + keyword, + list_, + string, + union, +) from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -22,6 +33,10 @@ class Sft(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "concentration": (("index",), ("string",)), "constant": (("index",), ("string",)), @@ -172,6 +187,7 @@ class StressPeriodData(Item): packagedata: Optional[list[Packagedata]] = list_( default=None, block="packagedata", + tagged=False, write_if_empty=True, ) _stress_period_data: Optional[dict[int, list[StressPeriodData]]] = list_( @@ -180,6 +196,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) diff --git a/flopy4/mf6/gwt/src.py b/flopy4/mf6/gwt/src.py index 70f781db..a50ab96e 100644 --- a/flopy4/mf6/gwt/src.py +++ b/flopy4/mf6/gwt/src.py @@ -8,7 +8,7 @@ from flopy4.mf6._types import TimeSeriesRef, to_array from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, child, double, keyword, list_, string from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -20,6 +20,10 @@ class Src(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "src": (("cellid",), ("string",)), "to-mvr": (("cellid",), ("string",)), @@ -92,6 +96,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) @property diff --git a/flopy4/mf6/gwt/ssm.py b/flopy4/mf6/gwt/ssm.py index 6d0b6b00..fdb8be24 100644 --- a/flopy4/mf6/gwt/ssm.py +++ b/flopy4/mf6/gwt/ssm.py @@ -49,11 +49,13 @@ class Fileinput(Item): sources: Optional[list[Sources]] = list_( default=None, block="sources", + tagged=False, write_if_empty=True, ) fileinput: Optional[list[Fileinput]] = list_( default=None, block="fileinput", + tagged=False, ) diff --git a/flopy4/mf6/gwt/uzt.py b/flopy4/mf6/gwt/uzt.py index 0d716ae9..3609bae0 100644 --- a/flopy4/mf6/gwt/uzt.py +++ b/flopy4/mf6/gwt/uzt.py @@ -10,7 +10,18 @@ from flopy4.mf6.item import Item from flopy4.mf6.legacy import Legacy from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, child, double, file, integer, keyword, list_, string, union +from flopy4.mf6.spec import ( + Header, + array, + child, + double, + file, + integer, + keyword, + list_, + string, + union, +) from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -22,6 +33,10 @@ class Uzt(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "concentration": (("index",), ("string",)), "constant": (("index",), ("string",)), @@ -160,6 +175,7 @@ class StressPeriodData(Item): packagedata: Optional[list[Packagedata]] = list_( default=None, block="packagedata", + tagged=False, write_if_empty=True, ) _stress_period_data: Optional[dict[int, list[StressPeriodData]]] = list_( @@ -168,6 +184,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) diff --git a/flopy4/mf6/legacy.py b/flopy4/mf6/legacy.py index b4a34d4c..b65636e7 100644 --- a/flopy4/mf6/legacy.py +++ b/flopy4/mf6/legacy.py @@ -106,7 +106,7 @@ def _periods(value: Any) -> dict[int, Any]: return dict(value) if isinstance(value, Mapping) else {0: value} -def sto_period_data(steady_state: Any = None, transient: Any = None) -> dict[int, list]: +def sto_period_data(steady_state: Any = None, transient: Any = None) -> dict[int, str]: """STO's `stress_period_data` from flopy3's `steady_state` and `transient`. Each is `{kper: True}`, `True` (period 0), or a list of periods. A period can't be both.""" @@ -120,12 +120,12 @@ def periods(value: Any) -> list[int]: return [kper for kper, on in value.items() if on] return list(value) - data: dict[int, list] = {} - for word, value in (("STEADY-STATE", steady_state), ("TRANSIENT", transient)): + data: dict[int, str] = {} + for word, value in (("steady-state", steady_state), ("transient", transient)): for kper in periods(value): if kper in data: raise ValueError(f"period {kper} is both steady-state and transient") - data[kper] = [(word,)] + data[kper] = word return dict(sorted(data.items())) diff --git a/flopy4/mf6/olf/cdb.py b/flopy4/mf6/olf/cdb.py index 5cb48dfe..ee9254f9 100644 --- a/flopy4/mf6/olf/cdb.py +++ b/flopy4/mf6/olf/cdb.py @@ -8,7 +8,7 @@ from flopy4.mf6._types import TimeSeriesRef, to_array from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, integer, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, child, double, integer, keyword, list_, string from flopy4.mf6.utl.obs import Obs @@ -19,6 +19,10 @@ class Cdb(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "cdb": (("cellid",), ("string",)), "to-mvr": (("cellid",), ("string",)), @@ -77,6 +81,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) @property diff --git a/flopy4/mf6/olf/chd.py b/flopy4/mf6/olf/chd.py index a6ffe258..77841f5e 100644 --- a/flopy4/mf6/olf/chd.py +++ b/flopy4/mf6/olf/chd.py @@ -8,7 +8,7 @@ from flopy4.mf6._types import TimeSeriesRef, to_array from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, child, double, keyword, list_, string from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -20,6 +20,10 @@ class Chd(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "chd": (("cellid",), ("string",)), } @@ -85,6 +89,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) @property diff --git a/flopy4/mf6/olf/disv1d.py b/flopy4/mf6/olf/disv1d.py index 4119c807..ec79f251 100644 --- a/flopy4/mf6/olf/disv1d.py +++ b/flopy4/mf6/olf/disv1d.py @@ -124,11 +124,13 @@ class Cell2d(Item): vertices: Optional[list[Vertices]] = list_( default=None, block="vertices", + tagged=False, shape=("nvert",), ) cell2d: Optional[list[Cell2d]] = list_( default=None, block="cell2d", + tagged=False, shape=("nodes",), ) diff --git a/flopy4/mf6/olf/disv2d.py b/flopy4/mf6/olf/disv2d.py index 98362597..c60eae7f 100644 --- a/flopy4/mf6/olf/disv2d.py +++ b/flopy4/mf6/olf/disv2d.py @@ -110,11 +110,13 @@ class Cell2d(Item): vertices: Optional[list[Vertices]] = list_( default=None, block="vertices", + tagged=False, shape=("nvert",), ) cell2d: Optional[list[Cell2d]] = list_( default=None, block="cell2d", + tagged=False, shape=("nodes",), ) diff --git a/flopy4/mf6/olf/evp.py b/flopy4/mf6/olf/evp.py index dd773af9..5feba0ed 100644 --- a/flopy4/mf6/olf/evp.py +++ b/flopy4/mf6/olf/evp.py @@ -8,7 +8,7 @@ from flopy4.mf6._types import TimeSeriesRef, to_array from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, child, double, keyword, list_, string from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -20,6 +20,10 @@ class Evp(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "evp": (("cellid",), ("string",)), } @@ -85,6 +89,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) @property diff --git a/flopy4/mf6/olf/flw.py b/flopy4/mf6/olf/flw.py index 5799319c..561805e0 100644 --- a/flopy4/mf6/olf/flw.py +++ b/flopy4/mf6/olf/flw.py @@ -8,7 +8,7 @@ from flopy4.mf6._types import TimeSeriesRef, to_array from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, child, double, keyword, list_, string from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -20,6 +20,10 @@ class Flw(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "flw": (("cellid",), ("string",)), "to-mvr": (("cellid",), ("string",)), @@ -86,6 +90,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) @property diff --git a/flopy4/mf6/olf/oc.py b/flopy4/mf6/olf/oc.py index 3656fb31..75e94a59 100644 --- a/flopy4/mf6/olf/oc.py +++ b/flopy4/mf6/olf/oc.py @@ -8,7 +8,7 @@ from flopy4.mf6.legacy import Legacy, oc_period_data from flopy4.mf6.package import Package from flopy4.mf6.record import Record -from flopy4.mf6.spec import array, file, integer, list_, record, string, union +from flopy4.mf6.spec import Header, array, file, integer, list_, record, string, union @attrs.define(kw_only=True, slots=False) @@ -16,6 +16,10 @@ class Oc(Package): dfn_name: ClassVar[str] = "olf-oc" ftype: ClassVar[str] = "OC6" + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + legacy_kwargs: ClassVar[dict[str, Legacy]] = { "saverecord": Legacy("stress_period_data", oc_period_data), "printrecord": Legacy("stress_period_data", oc_period_data), diff --git a/flopy4/mf6/olf/pcp.py b/flopy4/mf6/olf/pcp.py index 46ac1802..5e6dce6a 100644 --- a/flopy4/mf6/olf/pcp.py +++ b/flopy4/mf6/olf/pcp.py @@ -8,7 +8,7 @@ from flopy4.mf6._types import TimeSeriesRef, to_array from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, child, double, keyword, list_, string from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -20,6 +20,10 @@ class Pcp(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "pcp": (("cellid",), ("string",)), } @@ -85,6 +89,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) @property diff --git a/flopy4/mf6/olf/sto.py b/flopy4/mf6/olf/sto.py index 79723ee0..bcae8bd4 100644 --- a/flopy4/mf6/olf/sto.py +++ b/flopy4/mf6/olf/sto.py @@ -1,12 +1,11 @@ # autogenerated file, do not modify -from typing import ClassVar, Optional +from typing import ClassVar, Literal, Optional import attrs -from flopy4.mf6.item import Item from flopy4.mf6.legacy import Legacy, sto_period_data from flopy4.mf6.package import Package -from flopy4.mf6.spec import keyword, list_, string +from flopy4.mf6.spec import Header, keyword, string @attrs.define(kw_only=True, slots=False) @@ -14,15 +13,15 @@ class Sto(Package): dfn_name: ClassVar[str] = "olf-sto" ftype: ClassVar[str] = "STO6" + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + legacy_kwargs: ClassVar[dict[str, Legacy]] = { "steady_state": Legacy("stress_period_data", sto_period_data), "transient": Legacy("stress_period_data", sto_period_data), } - @attrs.define - class StressPeriodData(Item): - stress_period_data: str = string() - save_flows: bool = keyword( default=False, block="options", @@ -35,13 +34,10 @@ class StressPeriodData(Item): optional=True, longname="export array variables to layered ascii files.", ) - _stress_period_data: Optional[dict[int, list[StressPeriodData]]] = list_( - alias="stress_period_data", + stress_period_data: Optional[dict[int, Literal["steady-state", "transient"]]] = string( default=None, - repr=False, block="period", fill_forward=True, + valid=("steady-state", "transient"), + tagged=False, ) - - -StoStressPeriodData = Sto.StressPeriodData diff --git a/flopy4/mf6/olf/zdg.py b/flopy4/mf6/olf/zdg.py index ec600967..7cb93780 100644 --- a/flopy4/mf6/olf/zdg.py +++ b/flopy4/mf6/olf/zdg.py @@ -8,7 +8,7 @@ from flopy4.mf6._types import TimeSeriesRef, to_array from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, child, double, integer, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, child, double, integer, keyword, list_, string from flopy4.mf6.utl.obs import Obs from flopy4.mf6.utl.ts import Ts @@ -20,6 +20,10 @@ class Zdg(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { "to-mvr": (("cellid",), ("string",)), "zdg": (("cellid",), ("string",)), @@ -83,6 +87,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) @property diff --git a/flopy4/mf6/prt/disv.py b/flopy4/mf6/prt/disv.py index 178a98f2..d48c38bb 100644 --- a/flopy4/mf6/prt/disv.py +++ b/flopy4/mf6/prt/disv.py @@ -131,11 +131,13 @@ class Cell2d(Item): vertices: Optional[list[Vertices]] = list_( default=None, block="vertices", + tagged=False, shape=("nvert",), ) cell2d: Optional[list[Cell2d]] = list_( default=None, block="cell2d", + tagged=False, shape=("ncpl",), ) diff --git a/flopy4/mf6/prt/fmi.py b/flopy4/mf6/prt/fmi.py index 534f04fe..566f59e7 100644 --- a/flopy4/mf6/prt/fmi.py +++ b/flopy4/mf6/prt/fmi.py @@ -28,6 +28,7 @@ class Packagedata(Item): packagedata: Optional[list[Packagedata]] = list_( default=None, block="packagedata", + tagged=False, ) diff --git a/flopy4/mf6/prt/oc.py b/flopy4/mf6/prt/oc.py index fa409f64..a13016eb 100644 --- a/flopy4/mf6/prt/oc.py +++ b/flopy4/mf6/prt/oc.py @@ -7,7 +7,7 @@ from flopy4.mf6.item import Item from flopy4.mf6.legacy import Legacy, oc_period_data from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, double, file, integer, keyword, list_, string, union +from flopy4.mf6.spec import Header, array, double, file, integer, keyword, list_, string, union @attrs.define(kw_only=True, slots=False) @@ -15,6 +15,10 @@ class Oc(Package): dfn_name: ClassVar[str] = "prt-oc" ftype: ClassVar[str] = "OC6" + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + legacy_kwargs: ClassVar[dict[str, Legacy]] = { "saverecord": Legacy("stress_period_data", oc_period_data), "printrecord": Legacy("stress_period_data", oc_period_data), @@ -143,6 +147,7 @@ class Print(Item): tracktimes: Optional[list[Tracktimes]] = list_( default=None, block="tracktimes", + tagged=False, shape=("ntracktimes",), ) _stress_period_data: Optional[dict[int, list[_StressPeriodDataItem]]] = list_( diff --git a/flopy4/mf6/prt/prp.py b/flopy4/mf6/prt/prp.py index 9fc6a0d5..02928098 100644 --- a/flopy4/mf6/prt/prp.py +++ b/flopy4/mf6/prt/prp.py @@ -7,7 +7,7 @@ from flopy4.mf6.item import Item from flopy4.mf6.legacy import Legacy from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, cellid_, double, file, integer, keyword, list_, string +from flopy4.mf6.spec import Header, array, cellid_, double, file, integer, keyword, list_, string @attrs.define(kw_only=True, slots=False) @@ -17,6 +17,10 @@ class Prp(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + legacy_kwargs: ClassVar[dict[str, Legacy]] = { "perioddata": Legacy("stress_period_data"), } @@ -165,11 +169,13 @@ class Fraction(Item): packagedata: Optional[list[Packagedata]] = list_( default=None, block="packagedata", + tagged=False, shape=("nreleasepts",), ) releasetimes: Optional[list[Releasetimes]] = list_( default=None, block="releasetimes", + tagged=False, shape=("nreleasetimes",), ) _stress_period_data: Optional[dict[int, list[_StressPeriodDataItem]]] = list_( diff --git a/flopy4/mf6/simulation.py b/flopy4/mf6/simulation.py index 217e7a35..390c1d3d 100644 --- a/flopy4/mf6/simulation.py +++ b/flopy4/mf6/simulation.py @@ -8,7 +8,7 @@ from flopy4.mf6.model import Model from flopy4.mf6.simulation_methods import SimulationMethods from flopy4.mf6.solution import Solution -from flopy4.mf6.spec import child, integer, keyword, string +from flopy4.mf6.spec import Header, child, integer, keyword, string from flopy4.mf6.tdis import Tdis from flopy4.mf6.utl.hpc import Hpc @@ -17,6 +17,10 @@ class Simulation(SimulationMethods, WorkspaceComponent): dfn_name: ClassVar[str] = "sim-nam" + headers: ClassVar[dict[str, Header]] = { + "solutiongroup": Header("integer"), + } + continue_: bool = keyword( default=False, block="options", diff --git a/flopy4/mf6/spec.py b/flopy4/mf6/spec.py index 776d7c5e..87dba09b 100644 --- a/flopy4/mf6/spec.py +++ b/flopy4/mf6/spec.py @@ -6,8 +6,18 @@ import builtins import types from datetime import datetime +from functools import cache from pathlib import Path -from typing import Any, Literal, TypedDict, Union, Unpack, get_args, get_origin +from typing import ( + Any, + Literal, + NamedTuple, + TypedDict, + Union, + Unpack, + get_args, + get_origin, +) import attrs import numpy as np @@ -22,8 +32,10 @@ to_ts_value, to_ts_values, ) -from flopy4.mf6.item import to_union_arm +from flopy4.mf6.item import item_list_type, item_list_words, to_union_arm +from flopy4.mf6.record import record_type from flopy4.spec import fields_dict as flopy_fields_dict +from flopy4.spec import is_array FieldType = Literal["keyword", "integer", "double", "string", "list", "record"] @@ -111,6 +123,8 @@ def _field(type_: str, kwargs: FieldKwargs, **attributes) -> Any: for key in ("block", "longname", "optional", "netcdf", "tagged", "when"): if kwargs.get(key): metadata[key] = kwargs[key] # type: ignore[literal-required] + if kwargs.get("tagged") is False: + metadata["tagged"] = False metadata.update({k: v for k, v in attributes.items() if v not in (None, False, ())}) on_setattr = kwargs.get("on_setattr") if kwargs.get("block") == "dimensions": @@ -166,6 +180,21 @@ def _ts_converter(kwargs: FieldKwargs, converter) -> None: kwargs.setdefault("converter", converter) +def _to_valid(valid: tuple[str, ...]): + """A converter spelling a string as the one of ``valid`` it matches + ignoring case (MF6 reads words so), and each of a per-period dict's.""" + spelled = {v.lower(): v for v in valid} + + def convert(value): + if isinstance(value, str): + return spelled.get(value.lower(), value) + if isinstance(value, dict): + return {k: convert(v) for k, v in value.items()} + return value + + return convert + + def keyword(**kwargs: Unpack[FieldKwargs]) -> Any: """A keyword: a flag, present or not.""" kwargs["tagged"] = True @@ -180,6 +209,8 @@ def string( scope: str | None = None, rule: str | None = None, empty_is_none: bool = False, + fill_forward: bool = False, + valid: tuple[str, ...] = (), **kwargs: Unpack[FieldKwargs], ) -> Any: """A string. A time series one may name a time series instead. It can't @@ -188,13 +219,28 @@ def string( only within the value of another column, its ``scope`` (MVR's ``pname`` within ``mname``). An fk may have a ``rule``, which picks the component it names in, or with a scope narrows its keys (MVR's - ``pname``, packages with ``mover`` on); see `flopy4.mf6.keys`.""" + ``pname``, packages with ``mover`` on); see `flopy4.mf6.keys`. + A ``fill_forward`` one is given per period (STO's steady-state or + transient), a period without one keeping the last's. One of ``valid`` + is kept as ``valid`` spells it, whatever its case.""" + if valid: + _convert_first(kwargs, _to_valid(valid)) if time_series: _ts_converter(kwargs, to_ts_value) if empty_is_none: _convert_first(kwargs, _empty_to_none) _validate(kwargs, _not_empty) - return _field("string", kwargs, time_series=time_series, pk=pk, fk=fk, scope=scope, rule=rule) + return _field( + "string", + kwargs, + time_series=time_series, + pk=pk, + fk=fk, + scope=scope, + rule=rule, + fill_forward=fill_forward, + valid=valid, + ) def integer( @@ -549,24 +595,22 @@ def fields_dict(cls) -> dict[str, Attribute]: return {k: v for k, v in fields.items() if "block" in v.metadata} -def repeating_array_key_type(field_type) -> type | None: - """For ``Optional[dict[K, IntArrayLike | FloatArrayLike]]``, return - ``K`` -- the header type of a block that repeats (e.g. utl-tas's "time" - block), whose own array field is keyed by header value. Returns - ``None`` for anything else, including a plain array and an - ``Optional[dict[int, list[ItemClass]]]`` period Item-list (see - ``item.item_list_type``) -- structurally distinct shapes, detected from - the annotation itself rather than a metadata flag, the same way - ``item_list_type`` reads its own dict-wrapped shape. Period array - fields (RCHA's recharge) have this shape too, keyed by period; callers - tell them apart by their ``fill_forward`` metadata. - """ - args = get_args(field_type) - inner = next((a for a in args if a is not type(None)), None) - if inner is None or get_origin(inner) is not dict: - return None - key, val = get_args(inner) - return key if val in (IntArrayLike, FloatArrayLike) else None +@cache +def binding_fields(cls) -> dict[str, list[tuple[Attribute, str, tuple[type, ...]]]]: + """The child fields named by a block's rows (a model's packages, the + simulation's models, exchanges and solutions), by block, in field + order, each with its kind and candidate classes (see + `child_field_candidates`). A file record's child (``NCF6 FILEIN + ``) loads with its record, so isn't one.""" + from flopy4.attrs_xarray import child_field_candidates + + out: dict[str, list] = {} + for f in attrs.fields(cls): + if not f.metadata.get("child") or "block" not in f.metadata or f.metadata.get("_keyword"): + continue + if (spec := child_field_candidates(f)) is not None: + out.setdefault(f.metadata["block"], []).append((f, *spec)) + return out def to_field_type(t: type) -> FieldType: @@ -633,3 +677,130 @@ def block_sort_key(item) -> int: return 4 else: return 3 + + +class Header(NamedTuple): + """A repeating block's header kind, as codegen records it in a + component class's ``headers``: ``integer`` (a period's IPER, + SOLUTIONGROUP's number), ``double`` (a TAS time) or ``record`` (OBS's + ``FILEOUT ``), and whether an integer is an index, 1-based in the + file and 0-based in memory (IPER is, the DFN's ``index``).""" + + kind: str + index: bool = False # type: ignore[assignment] + + +def computed_fields(cls) -> tuple[str, ...]: + """A class's fields that are written but not stored: a list package's + MAXBOUND, a property counting its rows, the only kind there is. It's the + first of its DIMENSIONS block.""" + return ("maxbound",) if isinstance(getattr(cls, "maxbound", None), property) else () + + +@cache +def file_blocks(cls) -> dict[str, list[Attribute]]: + """A class's blocks in file order, each with its fields in file order: + options and dimensions first, so a block can read by those before it. A + list package's DIMENSIONS block may hold only its computed MAXBOUND, so + has no fields.""" + blocks: dict[str, list[Attribute]] = {} + for a in attrs.fields(cls): + if (block := a.metadata.get("block")) and a.init is not False: + blocks.setdefault(block, []).append(a) + if computed_fields(cls) and "dimensions" not in blocks: + names = list(blocks) + names.insert(1 if names[:1] == ["options"] else 0, "dimensions") + blocks = {name: blocks.get(name, []) for name in names} + return blocks + + +@attrs.frozen +class BlockKeys: + """How the rows of one of a class's blocks find their fields. + + Attributes + ---------- + tagged : + Fields by the keyword their rows begin with, in file order. Where a + keyword begins more than one field's rows (OC's ``HEAD``), the next + keyword tells them apart (see ``following_tags``). + dynamic : + Fields whose rows begin with a value of another field instead, by + that field's path: RCHA's ``aux``, by ``options.auxiliary``. + untagged : + The field the block's other rows belong to, if any. + computed : + Keywords of fields with no attribute (see ``computed_fields``). + """ + + tagged: dict[str, tuple[Attribute, ...]] + dynamic: dict[str, Attribute] + untagged: Attribute | None + computed: tuple[str, ...] = () + + +def is_tagged(f: Attribute) -> bool: + """Whether a component field's rows begin with a keyword. Its metadata + says only when they don't, unlike a record's columns, which say only + when they do.""" + return f.metadata.get("tagged", True) + + +def _record_words(record: type) -> tuple[str, ...]: + """The keywords a record or list item's row can begin with.""" + keyword = vars(record).get("_keyword") + return (keyword.lower(), *vars(record).get("_aliases", ())) if keyword else () + + +def leading_tags(f: Attribute) -> tuple[str, ...]: + """The keywords a tagged field's rows can begin with: a file record's + keyword, a record's, each of a list's items' and words, else its own + name, as it is in the file (``list_`` is ``LIST``).""" + if keyword := f.metadata.get("_keyword"): + return (keyword,) + if (record := record_type(f.type)) is not None and (words := _record_words(record)): + return words + if (item := item_list_type(f.type)) is not None: + items = item if isinstance(item, tuple) else (item,) + words = tuple(w for c in items for w in _record_words(c)) + return words + tuple(w.lower() for w in item_list_words(f.type)) + return (field_key(f),) + + +def following_tags(f: Attribute) -> list[str]: + """The keywords that can follow the one ``f``'s rows begin with: a file + record's direction, or a record's next keyword (OC's ``HEAD FILEOUT`` + and ``HEAD PRINT_FORMAT``).""" + if f.metadata.get("_keyword"): + direction = f.metadata.get("direction") + return [f"file{direction}"] if direction else [] + if (record := record_type(f.type)) is not None: + return [t.lower() for t in vars(record).get("_extra_tokens", ())[:1]] + return [] + + +def field_key(f: Attribute) -> str: + """A field's name in the file and to the writer: its attribute's, less + the underscores that keep it private or off a Python keyword.""" + return f.name.strip("_") + + +@cache +def block_keys(cls, block: str) -> BlockKeys: + """How the rows of ``block`` find ``cls``'s fields. The rows naming + children aren't keyed: see `binding_fields`.""" + tagged: dict[str, tuple[Attribute, ...]] = {} + dynamic: dict[str, Attribute] = {} + untagged = None + for f in file_blocks(cls).get(block, ()): + if f.metadata.get("row"): + continue + if not is_tagged(f): + untagged = f + elif f.metadata.get("fk") and is_array(f): + dynamic[f.metadata["fk"]] = f + else: + for tag in leading_tags(f): + tagged[tag] = (*tagged.get(tag, ()), f) + computed = computed_fields(cls) if block == "dimensions" else () + return BlockKeys(tagged=tagged, dynamic=dynamic, untagged=untagged, computed=computed) diff --git a/flopy4/mf6/tdis.py b/flopy4/mf6/tdis.py index 7f8cae22..fa35434e 100644 --- a/flopy4/mf6/tdis.py +++ b/flopy4/mf6/tdis.py @@ -45,6 +45,7 @@ class Perioddata(Item): perioddata: Optional[list[Perioddata]] = list_( default=((1.0, 1, 1.0),), block="perioddata", + tagged=False, shape=("nper",), ) # type: ignore[assignment] diff --git a/flopy4/mf6/utils/codegen/filters.py b/flopy4/mf6/utils/codegen/filters.py index 5c4c7f7d..0f01efe0 100644 --- a/flopy4/mf6/utils/codegen/filters.py +++ b/flopy4/mf6/utils/codegen/filters.py @@ -129,6 +129,20 @@ def output_path(dfn_name: str, root: Path) -> Path: # Component/Block-level helpers +def headers(component: Component) -> dict[str, str]: + """The component's repeating blocks' headers, by block name, each as + the ``Header`` codegen writes for it: its field's type, and for an + integer whether the DFN marks it an index (a period's IPER).""" + out = {} + for name, block in (component.blocks or {}).items(): + if block.header is None: + continue + field = block.header.field + index = field.type == "integer" and bool(getattr(field, "index", False)) + out[name] = f'Header("{field.type}"{", index=True" if index else ""})' + return out + + def fill_forward_blocks(component: Component) -> frozenset[str]: """Names of the component's repeating blocks whose header fills forward (a missing occurrence reuses the prior one's values) -- ``period``, per diff --git a/flopy4/mf6/utils/codegen/make.py b/flopy4/mf6/utils/codegen/make.py index 7fbb6305..1810f0f0 100644 --- a/flopy4/mf6/utils/codegen/make.py +++ b/flopy4/mf6/utils/codegen/make.py @@ -186,6 +186,8 @@ class ComponentSpec: # Dims counting item columns that aren't fields, name -> DFN expression # Observation types the component's OBS file takes, name -> id forms observations: dict[str, tuple[tuple[str, ...], ...]] = dc_field(default_factory=dict) + # The repeating blocks' headers, block name -> Header(...) source + headers: dict[str, str] = dc_field(default_factory=dict) has_griddata: bool = False has_readarray_period: bool = False # A model subpackage's __all__: the model and its packages @@ -492,6 +494,13 @@ def _expand_record_field(f: Record, block_name: str) -> tuple[list[FieldSpec], l return specs, gen_fields +def _untagged(f: FieldV3) -> dict[str, bool]: + """A component field's ``tagged`` metadata: said only when it's untagged, + as the block's other rows belong to it. (A record's columns are the other + way round: see `Record`.)""" + return {} if getattr(f, "tagged", True) else {"tagged": False} + + def _ml_field( fn: str, default: str = "None", @@ -1704,21 +1713,34 @@ def _add_list_items(lf: ListField, class_name: str) -> str: _readarray_period_fields.append(f) continue - # STO-family (chf/gwf/olf-sto): a bare scalar directly in the period - # block ("storage", valid=["steady-state","transient"]) -- not a List, - # but still needs the same per-period, fill-forward dict[int, ...] - # treatment as any other period field (the whole point of a period - # block is that its contents can differ/repeat across BEGIN PERIOD - # blocks). One column, since there's nothing else in the block. + # STO-family (chf/gwf/olf-sto): one string per period, directly in + # the period block (the DFN's stress_period_data, valid steady-state + # or transient), as a value per period, filled forward. if block_name in _fill_forward_blocks and filters.is_scalar(f): - item_classes.append( - ItemClassSpec( - class_name="StressPeriodData", - keyword="", - schema=[filters.attr_column(f.name, "str", "string", {}, optional=False)], + valid = tuple(getattr(f, "valid", None) or ()) + words = ", ".join(repr(v) for v in valid) + period_specs.append( + FieldSpec( + dfn_name=f.name, + py_name="stress_period_data", + type_annotation=( + f"Optional[dict[int, Literal[{words}]]]" + if words + else "Optional[dict[int, str]]" + ), + spec_call=_ml_field( + "string", + metadata={ + "block": block_name, + "fill_forward": True, + "valid": valid, + **_untagged(f), + }, + ), + generatable=True, ) ) - _period_item = "StressPeriodData" + generatable_field_objects.append((block_name, f)) continue # maxbound: emitted as a computed property (see computed_field_specs @@ -1740,8 +1762,7 @@ def _add_list_items(lf: ListField, class_name: str) -> str: _repeating_block_meta: dict[str, Any] = {"block": block_name} if getattr(f, "shape", None): _repeating_block_meta["shape"] = tuple(f.shape) - if getattr(f, "tagged", True): - _repeating_block_meta["tagged"] = True + _repeating_block_meta |= _untagged(f) data_specs.append( FieldSpec( dfn_name=f.name, @@ -1803,6 +1824,7 @@ def _add_list_items(lf: ListField, class_name: str) -> str: ) generatable_field_objects.append((block_name, f)) elif filters.can_expand_record(f): + # a record spread over its members' own attributes specs, gen_fields = _expand_record_field(f, block_name) target.extend(specs) generatable_field_objects.extend((block_name, gf) for gf in gen_fields) @@ -1832,7 +1854,7 @@ def _add_list_items(lf: ListField, class_name: str) -> str: block_item_classes.extend(_specs) if _union is not None: item_unions.append(_union) - _meta: dict = {"block": bp.block_name} + _meta: dict = {"block": bp.block_name, **_untagged(_list_field)} _header = component.blocks[bp.block_name].header if _header is not None and isinstance(_header.field, Record): # The block repeats under a record header: a list of block @@ -1906,6 +1928,8 @@ def _add_list_items(lf: ListField, class_name: str) -> str: # block gets, in a dict keyed by period. if _period_item is not None: _spd_meta: dict[str, Any] = {"block": _ff_block, "fill_forward": True} + if _ff_list is not None: + _spd_meta |= _untagged(_ff_list) # The DIMENSIONS field bounding each period's rows, unless it's # computed (maxbound): HFB's "<=maxhfb". _ff_list computed above. if ( @@ -1933,6 +1957,7 @@ def _add_list_items(lf: ListField, class_name: str) -> str: # period array separately, keyed by the 0-based periods it's given in # (see flopy4.mf6.period_arrays). if _readarray_period_fields: + assert _ff_block is not None # they're its fields # a grid package's period can be cleared, None (see period_arrays) _grid = any(f.name == "readarraygrid" for _, f in all_fields) for _ra_f in _readarray_period_fields: @@ -1971,6 +1996,7 @@ def _add_list_items(lf: ListField, class_name: str) -> str: # period, then by the auxiliary names (the fk), each array like a READARRAY # period field's. for _lf, _arr, _fk in _dynamically_named_period_fields: + assert _ff_block is not None # they're its fields _na_meta: dict = {"block": _ff_block} if shape := getattr(_arr, "shape", None): _na_meta["shape"] = tuple(shape) @@ -2042,12 +2068,18 @@ def _block_index(fs: FieldSpec) -> int: ) legacy_kwargs = _legacy_kwargs(component) if legacy_kwargs: - if _period_item is None: - raise ValueError(f"{component.name}: legacy period keywords, but no period list") + # a period list, or STO's word per period + if _period_item is None and not any( + fs.py_name == "stress_period_data" for fs in period_specs + ): + raise ValueError(f"{component.name}: legacy period keywords, but no period data") extra_imports.extend( f"from flopy4.mf6.legacy import {convert or 'Legacy'}" for convert in {None, *(c for _, c in _LEGACY_PERIOD_KWARGS[component.name])} ) + _headers = filters.headers(component) + if _headers: + _spec_functions.add("Header") imports = _generated_imports( generatable_field_objects, base_class=base, @@ -2070,7 +2102,8 @@ def _block_index(fs: FieldSpec) -> int: fs.spec_call.startswith("child(") and "Union[" in fs.type_annotation for fs in field_specs ), - has_literal=any(u.words for u in item_unions), + has_literal=any(u.words for u in item_unions) + or any("Literal[" in fs.type_annotation for fs in field_specs), extra_imports=[ *extra_imports, *(["from flopy4.mf6.block import Block"] if block_classes else []), @@ -2115,6 +2148,7 @@ def _block_index(fs: FieldSpec) -> int: computed_fields=computed_field_specs, derived_dims=_derived_dims, shared_dims=shared_dims, + headers=_headers, observations={ name: tuple(_obs_forms(f)) for name, f in sorted((component.observations or {}).items()) }, diff --git a/flopy4/mf6/utils/codegen/templates/package.py.jinja b/flopy4/mf6/utils/codegen/templates/package.py.jinja index ad208af6..1f33edbe 100644 --- a/flopy4/mf6/utils/codegen/templates/package.py.jinja +++ b/flopy4/mf6/utils/codegen/templates/package.py.jinja @@ -36,6 +36,14 @@ class {{ spec.class_name }}({% for m in spec.mixins %}{{ m }}, {% endfor %}{{ sp {% if spec.shared_dims %} shared_dims: ClassVar[tuple[str, ...]] = {{ spec.shared_dims | tuple_repr }} +{% endif %} +{% if spec.headers %} + headers: ClassVar[dict[str, Header]] = { +{% for name, header in spec.headers.items() %} + "{{ name }}": {{ header }}, +{% endfor %} + } + {% endif %} {% if spec.observations %} observations: ClassVar[dict[str, tuple[tuple[str, ...], ...]]] = { diff --git a/flopy4/mf6/utl/ats.py b/flopy4/mf6/utl/ats.py index efa2de49..24570b41 100644 --- a/flopy4/mf6/utl/ats.py +++ b/flopy4/mf6/utl/ats.py @@ -30,6 +30,7 @@ class Perioddata(Item): perioddata: Optional[list[Perioddata]] = list_( default=None, block="perioddata", + tagged=False, shape=("<=maxats",), ) diff --git a/flopy4/mf6/utl/hpc.py b/flopy4/mf6/utl/hpc.py index f560141f..e31d98b5 100644 --- a/flopy4/mf6/utl/hpc.py +++ b/flopy4/mf6/utl/hpc.py @@ -27,6 +27,7 @@ class Partitions(Item): partitions: Optional[list[Partitions]] = list_( default=None, block="partitions", + tagged=False, ) diff --git a/flopy4/mf6/utl/laktab.py b/flopy4/mf6/utl/laktab.py index 0269ac78..1fe5d842 100644 --- a/flopy4/mf6/utl/laktab.py +++ b/flopy4/mf6/utl/laktab.py @@ -35,6 +35,7 @@ class Table(Item): table: Optional[list[Table]] = list_( default=None, block="table", + tagged=False, shape=("nrow",), ) diff --git a/flopy4/mf6/utl/obs.py b/flopy4/mf6/utl/obs.py index 1d056fc8..283ef86b 100644 --- a/flopy4/mf6/utl/obs.py +++ b/flopy4/mf6/utl/obs.py @@ -7,7 +7,7 @@ from flopy4.mf6.block import Block from flopy4.mf6.item import Item from flopy4.mf6.package import Package -from flopy4.mf6.spec import file, integer, keyword, list_, string, union +from flopy4.mf6.spec import Header, file, integer, keyword, list_, string, union @attrs.define(kw_only=True, slots=False) @@ -15,6 +15,10 @@ class Obs(Package): dfn_name: ClassVar[str] = "utl-obs" ftype: ClassVar[str] = "OBS6" + headers: ClassVar[dict[str, Header]] = { + "continuous": Header("record"), + } + @attrs.define class Continuous(Item): obsname: str = string() @@ -49,6 +53,7 @@ class ContinuousBlock(Block): continuous: Optional[list[ContinuousBlock]] = list_( default=None, block="continuous", + tagged=False, ) diff --git a/flopy4/mf6/utl/sfrtab.py b/flopy4/mf6/utl/sfrtab.py index f090d8d6..9b6bf38f 100644 --- a/flopy4/mf6/utl/sfrtab.py +++ b/flopy4/mf6/utl/sfrtab.py @@ -34,6 +34,7 @@ class Table(Item): table: Optional[list[Table]] = list_( default=None, block="table", + tagged=False, shape=("nrow",), ) diff --git a/flopy4/mf6/utl/spc.py b/flopy4/mf6/utl/spc.py index 5bac7af8..35f29aee 100644 --- a/flopy4/mf6/utl/spc.py +++ b/flopy4/mf6/utl/spc.py @@ -7,7 +7,7 @@ from flopy4.mf6.item import Item from flopy4.mf6.legacy import Legacy from flopy4.mf6.package import Package -from flopy4.mf6.spec import child, double, integer, keyword, list_, union +from flopy4.mf6.spec import Header, child, double, integer, keyword, list_, union from flopy4.mf6.utl.ts import Ts @@ -18,6 +18,10 @@ class Spc(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + legacy_kwargs: ClassVar[dict[str, Legacy]] = { "perioddata": Legacy("stress_period_data"), } @@ -57,6 +61,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, shape=("<=maxbound",), dim_required=True, ) diff --git a/flopy4/mf6/utl/spca.py b/flopy4/mf6/utl/spca.py index f0341397..d09eb616 100644 --- a/flopy4/mf6/utl/spca.py +++ b/flopy4/mf6/utl/spca.py @@ -5,7 +5,7 @@ from flopy4.mf6._types import FloatArrayLike, TimeArraySeriesRef from flopy4.mf6.package import Package -from flopy4.mf6.spec import array, child, keyword +from flopy4.mf6.spec import Header, array, child, keyword from flopy4.mf6.utl.tas import Tas @@ -16,6 +16,10 @@ class Spca(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + readasarrays: bool = keyword( default=True, block="options", diff --git a/flopy4/mf6/utl/tas.py b/flopy4/mf6/utl/tas.py index f0d37581..b244eaab 100644 --- a/flopy4/mf6/utl/tas.py +++ b/flopy4/mf6/utl/tas.py @@ -6,7 +6,7 @@ from flopy4.mf6._types import FloatArrayLike from flopy4.mf6.package import Package from flopy4.mf6.record import Record -from flopy4.mf6.spec import array, record, string +from flopy4.mf6.spec import Header, array, record, string @attrs.define(kw_only=True, slots=False) @@ -16,6 +16,10 @@ class Tas(Package): multi_package: ClassVar[bool] = True + headers: ClassVar[dict[str, Header]] = { + "time": Header("double"), + } + @attrs.define class TimeSeriesName(Record): _keyword: ClassVar[str] = "name" @@ -50,4 +54,5 @@ class Sfac(Record): default=None, block="time", shape=("ncpl",), + tagged=False, ) diff --git a/flopy4/mf6/utl/ts.py b/flopy4/mf6/utl/ts.py index 9ef725b6..b87c131c 100644 --- a/flopy4/mf6/utl/ts.py +++ b/flopy4/mf6/utl/ts.py @@ -76,6 +76,7 @@ class Timeseries(Item): timeseries: Optional[list[Timeseries]] = list_( default=None, block="timeseries", + tagged=False, write_if_empty=True, ) diff --git a/flopy4/mf6/utl/tvk.py b/flopy4/mf6/utl/tvk.py index afbd1a16..e6d9f8e7 100644 --- a/flopy4/mf6/utl/tvk.py +++ b/flopy4/mf6/utl/tvk.py @@ -7,7 +7,7 @@ from flopy4.mf6.item import Item from flopy4.mf6.legacy import Legacy from flopy4.mf6.package import Package -from flopy4.mf6.spec import cellid_, child, double, keyword, list_, union +from flopy4.mf6.spec import Header, cellid_, child, double, keyword, list_, union from flopy4.mf6.utl.ts import Ts @@ -16,6 +16,10 @@ class Tvk(Package): dfn_name: ClassVar[str] = "utl-tvk" ftype: ClassVar[str] = "TVK6" + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + legacy_kwargs: ClassVar[dict[str, Legacy]] = { "perioddata": Legacy("stress_period_data"), } @@ -55,6 +59,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) diff --git a/flopy4/mf6/utl/tvs.py b/flopy4/mf6/utl/tvs.py index 0f8eea19..e566dc7f 100644 --- a/flopy4/mf6/utl/tvs.py +++ b/flopy4/mf6/utl/tvs.py @@ -7,7 +7,7 @@ from flopy4.mf6.item import Item from flopy4.mf6.legacy import Legacy from flopy4.mf6.package import Package -from flopy4.mf6.spec import cellid_, child, double, keyword, list_, union +from flopy4.mf6.spec import Header, cellid_, child, double, keyword, list_, union from flopy4.mf6.utl.ts import Ts @@ -16,6 +16,10 @@ class Tvs(Package): dfn_name: ClassVar[str] = "utl-tvs" ftype: ClassVar[str] = "TVS6" + headers: ClassVar[dict[str, Header]] = { + "period": Header("integer", index=True), + } + legacy_kwargs: ClassVar[dict[str, Legacy]] = { "perioddata": Legacy("stress_period_data"), } @@ -56,6 +60,7 @@ class StressPeriodData(Item): repr=False, block="period", fill_forward=True, + tagged=False, ) diff --git a/flopy4/mf6/write_context.py b/flopy4/mf6/write_context.py index 49fbae49..958146a6 100644 --- a/flopy4/mf6/write_context.py +++ b/flopy4/mf6/write_context.py @@ -58,7 +58,9 @@ class ArrayIO: field, beside the component's file. A path outside the simulation directory isn't written to: the array is written beside its component's file instead, under the same name. Arrays sharing a - file must hold the same values, or they're written inline. + file must hold the same values, or they're written inline (to + files of their own, if the context's `array_format` is a file + format: see `WriteContext`). format : ArrayFormat, optional The control record to write the array with. Overrides the context's `array_format`. A ``(field, layer)`` entry's is for @@ -74,7 +76,13 @@ class ArrayIO: inline. Set by loading; not compared by `==`. Loading sets each array's `format` and `layered` to the control - records it was read from, so writing it again writes them back. + records it was read from, so writing it again writes them back. An + INTERNAL or OPEN/CLOSE record's FACTOR isn't kept: the array holds the + values times it, and is written with no FACTOR. Arrays read from one + file with different factors (say, a recharge file scaled per period) + so hold different values, and can't share the file when written: + they're written inline, or each to a file of its own with an + `array_format` of "open/close". """ iprn: Optional[int] = None @@ -183,6 +191,10 @@ class WriteContext: field. Set here, it overrides lower-ranked contexts' formats, such as loaded ones, and, if "constant" or "internal", their paths; an `ArrayIO.path` of this context still writes its array to the file. + Arrays sent to a file by it that can't share the file their path + names, holding different values, each get a file of their own, + named as if they had no path, where they'd otherwise be written + inline. `use_netcdf` overrides it. list_format : ListFormat, optional How to write lists, unless a list's own `ListIO.format` in this diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001a_Tharmonic_extlist].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001a_Tharmonic_extlist].json index dcff055e..e2285e93 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001a_Tharmonic_extlist].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001a_Tharmonic_extlist].json @@ -143,8 +143,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow15.ims flow15", " MXITER 1", + " IMS6 flow15.ims flow15", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001b_Tlogarithmic].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001b_Tlogarithmic].json index 6ac44af8..0104e614 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001b_Tlogarithmic].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001b_Tlogarithmic].json @@ -137,8 +137,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow15.ims flow15", " MXITER 1", + " IMS6 flow15.ims flow15", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001c_Tamtlmk].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001c_Tamtlmk].json index 8d93e57d..7b5107c0 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001c_Tamtlmk].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001c_Tamtlmk].json @@ -137,8 +137,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow15.ims flow15", " MXITER 1", + " IMS6 flow15.ims flow15", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001d_Tnewton].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001d_Tnewton].json index 75abb749..6dd6aa2a 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001d_Tnewton].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001d_Tnewton].json @@ -137,8 +137,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow15.ims flow15", " MXITER 1", + " IMS6 flow15.ims flow15", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_Tnewton_2models].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_Tnewton_2models].json index a8555eca..b3372017 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_Tnewton_2models].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_Tnewton_2models].json @@ -17,8 +17,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims Model_01 Model_02", " MXITER 1", + " IMS6 model.ims Model_01 Model_02", "END SOLUTIONGROUP 1" ], "model.exg": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_UZF_3layTS].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_UZF_3layTS].json index 3c571a8c..5bbce87c 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_UZF_3layTS].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_UZF_3layTS].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 test001e_UZF_3lay.ims GWF_1", " MXITER 1", + " IMS6 test001e_UZF_3lay.ims GWF_1", "END SOLUTIONGROUP 1" ], "simulation.tdis": [ @@ -171,11 +171,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " transient", + " TRANSIENT", "END PERIOD 1", "", "BEGIN PERIOD 2", - " TRANSIENT", + " TRANSIENT", "END PERIOD 2" ], "test001e_UZF_3lay.uzf": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_UZF_3lay].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_UZF_3lay].json index cbfe552e..65951c8d 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_UZF_3lay].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_UZF_3lay].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 test001e_UZF_3lay.ims GWF_1", " MXITER 1", + " IMS6 test001e_UZF_3lay.ims GWF_1", "END SOLUTIONGROUP 1" ], "simulation.tdis": [ @@ -172,11 +172,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " transient", + " TRANSIENT", "END PERIOD 1", "", "BEGIN PERIOD 2", - " TRANSIENT", + " TRANSIENT", "END PERIOD 2" ], "test001e_UZF_3lay.uzf": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_UZF_TS].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_UZF_TS].json index 13c6bd98..d94ded11 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_UZF_TS].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_UZF_TS].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 test001e_UZF_TS.ims GWF_1", " MXITER 1", + " IMS6 test001e_UZF_TS.ims GWF_1", "END SOLUTIONGROUP 1" ], "simulation.tdis": [ @@ -167,11 +167,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " transient", + " TRANSIENT", "END PERIOD 1", "", "BEGIN PERIOD 2", - " TRANSIENT", + " TRANSIENT", "END PERIOD 2" ], "test001e_UZF_TS.uzf": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_UZF_spring].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_UZF_spring].json index 40af6322..2333c207 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_UZF_spring].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_UZF_spring].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 test001e_UZF.ims GWF_1", " MXITER 1", + " IMS6 test001e_UZF.ims GWF_1", "END SOLUTIONGROUP 1" ], "simulation.tdis": [ @@ -170,11 +170,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " STEADY-STATE", + " STEADY-STATE", "END PERIOD 1", "", "BEGIN PERIOD 2", - " TRANSIENT", + " TRANSIENT", "END PERIOD 2" ], "test001e_UZF.uzf": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_noUZF_3lay].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_noUZF_3lay].json index 6c2d238f..02c97356 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_noUZF_3lay].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001e_noUZF_3lay].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 test001e_noUZF.ims GWF_1", " MXITER 1", + " IMS6 test001e_noUZF.ims GWF_1", "END SOLUTIONGROUP 1" ], "simulation.tdis": [ @@ -182,11 +182,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " transient", + " TRANSIENT", "END PERIOD 1", "", "BEGIN PERIOD 2", - " TRANSIENT", + " TRANSIENT", "END PERIOD 2" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001f_hfb-xt3d-nwt].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001f_hfb-xt3d-nwt].json index c0e9711e..2e654c06 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001f_hfb-xt3d-nwt].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001f_hfb-xt3d-nwt].json @@ -153,8 +153,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow15.ims flow15", " MXITER 1", + " IMS6 flow15.ims flow15", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001f_hfb-xt3d].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001f_hfb-xt3d].json index 4b6b396a..88966d4a 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001f_hfb-xt3d].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001f_hfb-xt3d].json @@ -152,8 +152,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow15.ims flow15", " MXITER 1", + " IMS6 flow15.ims flow15", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001f_hfb].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001f_hfb].json index 8beb96de..ad5ddc50 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001f_hfb].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001f_hfb].json @@ -150,8 +150,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow15.ims flow15", " MXITER 1", + " IMS6 flow15.ims flow15", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001g_MVR].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001g_MVR].json index bf91795f..8c1891f5 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001g_MVR].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001g_MVR].json @@ -213,8 +213,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow15.ims flow15", " MXITER 1", + " IMS6 flow15.ims flow15", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001g_MVR_transient].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001g_MVR_transient].json index 9f809315..673b8060 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001g_MVR_transient].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest001g_MVR_transient].json @@ -227,8 +227,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow15.ims flow15", " MXITER 1", + " IMS6 flow15.ims flow15", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs].json index cd2ab4c5..54493900 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.dis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs_disv].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs_disv].json index 26b08161..d83b332c 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs_disv].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs_disv].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.disv": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs_disv_xt3d].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs_disv_xt3d].json index ae33f5a1..2c445ad1 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs_disv_xt3d].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs_disv_xt3d].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.disv": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs_obs].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs_obs].json index cd2ab4c5..54493900 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs_obs].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs_obs].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.dis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs_reduced].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs_reduced].json index 979d415f..b3166519 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs_reduced].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs_reduced].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.dis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs_tr].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs_tr].json index 7975057c..930a7f97 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs_tr].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest003_gwfs_tr].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.dis": [ @@ -132,11 +132,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " steady-state", + " STEADY-STATE", "END PERIOD 1", "", "BEGIN PERIOD 2", - " transient", + " TRANSIENT", "END PERIOD 2" ], "model_left.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest004_bcfss].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest004_bcfss].json index fd3290f5..7f0e9d96 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest004_bcfss].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest004_bcfss].json @@ -143,8 +143,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest004_lpfss].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest004_lpfss].json index b1288fba..0fa372c3 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest004_lpfss].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest004_lpfss].json @@ -16,8 +16,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 test004_lpfss.ims test004_lpfss", " MXITER 1", + " IMS6 test004_lpfss.ims test004_lpfss", "END SOLUTIONGROUP 1" ], "test004_lpfss.dis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest004_lpfss_disv].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest004_lpfss_disv].json index a75326de..2dd8ba4c 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest004_lpfss_disv].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest004_lpfss_disv].json @@ -25,8 +25,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 t4.ims t4_disv", " MXITER 1", + " IMS6 t4.ims t4_disv", "END SOLUTIONGROUP 1" ], "t4.disv": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest004_lpfss_nr].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest004_lpfss_nr].json index cd8a46d7..8619f063 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest004_lpfss_nr].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest004_lpfss_nr].json @@ -16,8 +16,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 test004_lpfss_nr.ims test004_lpfss_nr", " MXITER 1", + " IMS6 test004_lpfss_nr.ims test004_lpfss_nr", "END SOLUTIONGROUP 1" ], "test004_lpfss_nr.dis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest005_advgw_tidal].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest005_advgw_tidal].json index aa015437..cc8cf137 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest005_advgw_tidal].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest005_advgw_tidal].json @@ -31,8 +31,8 @@ "END OPTIONS", "", "BEGIN DIMENSIONS", - " NSEG 3", " MAXBOUND 150", + " NSEG 3", "END DIMENSIONS", "", "BEGIN PERIOD 1", @@ -222,11 +222,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " STEADY-STATE", + " STEADY-STATE", "END PERIOD 1", "", "BEGIN PERIOD 2", - " TRANSIENT", + " TRANSIENT", "END PERIOD 2" ], "AdvGW_tidal.wel": [ @@ -337,8 +337,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_gnc].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_gnc].json index 35dc1f04..3b585fb4 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_gnc].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_gnc].json @@ -17,8 +17,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 simulation.ims GWF_Model_1 GWF_Model_2", " MXITER 1", + " IMS6 simulation.ims GWF_Model_1 GWF_Model_2", "END SOLUTIONGROUP 1" ], "model1.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_mvr_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_mvr_dev].json index 58b1322c..4d9edb6c 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_mvr_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_mvr_dev].json @@ -17,8 +17,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 simulation.ims PARENT CHILD", " MXITER 1", + " IMS6 simulation.ims PARENT CHILD", "END SOLUTIONGROUP 1" ], "model1.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_unconf].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_unconf].json index 5b6db4de..1ddd1cea 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_unconf].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_unconf].json @@ -17,8 +17,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 simulation.ims GWF_Model_1 GWF_Model_2", " MXITER 1", + " IMS6 simulation.ims GWF_Model_1 GWF_Model_2", "END SOLUTIONGROUP 1" ], "model1.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_unconf_nr].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_unconf_nr].json index d11e9583..eff32fca 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_unconf_nr].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_unconf_nr].json @@ -17,8 +17,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 simulation.ims GWF_Model_1 GWF_Model_2", " MXITER 1", + " IMS6 simulation.ims GWF_Model_1 GWF_Model_2", "END SOLUTIONGROUP 1" ], "model1.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_unconf_nr_gnc].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_unconf_nr_gnc].json index 56ee58b1..e904c065 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_unconf_nr_gnc].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_unconf_nr_gnc].json @@ -17,8 +17,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 simulation.ims GWF_Model_1 GWF_Model_2", " MXITER 1", + " IMS6 simulation.ims GWF_Model_1 GWF_Model_2", "END SOLUTIONGROUP 1" ], "model1.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_unconf_tr_nr].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_unconf_tr_nr].json index 001bd8f2..6b2b80b7 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_unconf_tr_nr].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_2models_unconf_tr_nr].json @@ -17,8 +17,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 simulation.ims GWF_Model_1 GWF_Model_2", " MXITER 1", + " IMS6 simulation.ims GWF_Model_1 GWF_Model_2", "END SOLUTIONGROUP 1" ], "model1.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3].json index 96e81ee0..55d72600 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3].json @@ -183,8 +183,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow.ims GWF_1", " MXITER 1", + " IMS6 flow.ims GWF_1", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv].json index 4519092f..b420de00 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv].json @@ -171,8 +171,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow.ims GWF_1", " MXITER 1", + " IMS6 flow.ims GWF_1", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_ext].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_ext].json index e4500f97..4b4bb459 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_ext].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_ext].json @@ -176,8 +176,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow.ims GWF_1", " MXITER 1", + " IMS6 flow.ims GWF_1", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_hani].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_hani].json index 19a9f3fa..5eca54b6 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_hani].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_hani].json @@ -176,8 +176,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow.ims GWF_1", " MXITER 1", + " IMS6 flow.ims GWF_1", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_trimesh2-3D_xt3d].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_trimesh2-3D_xt3d].json index 049284e2..3fd8dd85 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_trimesh2-3D_xt3d].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_trimesh2-3D_xt3d].json @@ -144,8 +144,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow.ims GWF_1", " MXITER 1", + " IMS6 flow.ims GWF_1", "END SOLUTIONGROUP 1" ], "simulation.tdis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_trimesh2].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_trimesh2].json index 4cc3bdb6..8cb5cd7e 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_trimesh2].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_trimesh2].json @@ -127,8 +127,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow.ims GWF_1", " MXITER 1", + " IMS6 flow.ims GWF_1", "END SOLUTIONGROUP 1" ], "simulation.tdis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_trimesh2_xt3d].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_trimesh2_xt3d].json index 24b26194..7af302af 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_trimesh2_xt3d].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_trimesh2_xt3d].json @@ -128,8 +128,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow.ims GWF_1", " MXITER 1", + " IMS6 flow.ims GWF_1", "END SOLUTIONGROUP 1" ], "simulation.tdis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_trimesh].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_trimesh].json index 0086171d..a312e9e8 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_trimesh].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_trimesh].json @@ -170,8 +170,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow.ims GWF_1", " MXITER 1", + " IMS6 flow.ims GWF_1", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_trimesh_xt3d].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_trimesh_xt3d].json index 1411392f..669f68e0 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_trimesh_xt3d].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_trimesh_xt3d].json @@ -155,8 +155,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow.ims GWF_1", " MXITER 1", + " IMS6 flow.ims GWF_1", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_xt3d].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_xt3d].json index a858cf80..c8fed09a 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_xt3d].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_disv_xt3d].json @@ -155,8 +155,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow.ims GWF_1", " MXITER 1", + " IMS6 flow.ims GWF_1", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_gnc].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_gnc].json index a62fc657..a5be5f5c 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_gnc].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_gnc].json @@ -185,8 +185,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow.ims GWF_1", " MXITER 1", + " IMS6 flow.ims GWF_1", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_gnc_nr_mfusg].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_gnc_nr_mfusg].json index b7a04d00..453ad2d7 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_gnc_nr_mfusg].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_gnc_nr_mfusg].json @@ -189,8 +189,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow.ims GWF_1", " MXITER 1", + " IMS6 flow.ims GWF_1", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_nr_mfusg].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_nr_mfusg].json index f02d1962..17e23ea9 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_nr_mfusg].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_nr_mfusg].json @@ -172,8 +172,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow.ims GWF_1", " MXITER 1", + " IMS6 flow.ims GWF_1", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_tr].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_tr].json index 4d167597..9e1206d6 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_tr].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_tr].json @@ -189,8 +189,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow.ims GWF_1", " MXITER 1", + " IMS6 flow.ims GWF_1", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_tr_nr].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_tr_nr].json index 979a9f36..1fcecfa9 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_tr_nr].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_tr_nr].json @@ -189,8 +189,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow.ims GWF_1", " MXITER 1", + " IMS6 flow.ims GWF_1", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_unconf].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_unconf].json index d619f930..d776d5f9 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_unconf].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006_gwf3_unconf].json @@ -169,8 +169,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow.ims GWF_1", " MXITER 1", + " IMS6 flow.ims GWF_1", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006a_gwf3_disv_thickstrt].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006a_gwf3_disv_thickstrt].json index e6e873cc..4ee6d351 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006a_gwf3_disv_thickstrt].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest006a_gwf3_disv_thickstrt].json @@ -171,8 +171,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow.ims GWF_1", " MXITER 1", + " IMS6 flow.ims GWF_1", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest007_75x75].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest007_75x75].json index 4f2872ed..166e372d 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest007_75x75].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest007_75x75].json @@ -147,15 +147,15 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " STEADY-STATE", + " STEADY-STATE", "END PERIOD 1", "", "BEGIN PERIOD 2", - " TRANSIENT", + " TRANSIENT", "END PERIOD 2", "", "BEGIN PERIOD 3", - " STEADY-STATE", + " STEADY-STATE", "END PERIOD 3" ], "mf6.tdis": [ @@ -208,8 +208,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 mf6.ims mf6", " MXITER 1", + " IMS6 mf6.ims mf6", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest007_75x75_confined].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest007_75x75_confined].json index 333c3cf2..2bfe8fe3 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest007_75x75_confined].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest007_75x75_confined].json @@ -147,15 +147,15 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " STEADY-STATE", + " STEADY-STATE", "END PERIOD 1", "", "BEGIN PERIOD 2", - " TRANSIENT", + " TRANSIENT", "END PERIOD 2", "", "BEGIN PERIOD 3", - " STEADY-STATE", + " STEADY-STATE", "END PERIOD 3" ], "mf6.tdis": [ @@ -208,8 +208,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 mf6.ims mf6", " MXITER 1", + " IMS6 mf6.ims mf6", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest009_3lay-disu].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest009_3lay-disu].json index f94bcf80..5893891c 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest009_3lay-disu].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest009_3lay-disu].json @@ -173,8 +173,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow.ims GWF_1", " MXITER 1", + " IMS6 flow.ims GWF_1", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest011_mflgr_ex3].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest011_mflgr_ex3].json index 47954195..b478714a 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest011_mflgr_ex3].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest011_mflgr_ex3].json @@ -275,8 +275,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 ex3_parent.ims PARENT CHILD", " MXITER 1", + " IMS6 ex3_parent.ims PARENT CHILD", "END SOLUTIONGROUP 1" ], "simulation.exg": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest011_mflgr_ex3_sfr].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest011_mflgr_ex3_sfr].json index 8808ddfa..a9619387 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest011_mflgr_ex3_sfr].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest011_mflgr_ex3_sfr].json @@ -289,8 +289,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 ex3_parent.ims PARENT CHILD", " MXITER 1", + " IMS6 ex3_parent.ims PARENT CHILD", "END SOLUTIONGROUP 1" ], "simulation.exg": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest012_WaterTable].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest012_WaterTable].json index 5daea029..c9ea2a8f 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest012_WaterTable].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest012_WaterTable].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest013_Zaidel].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest013_Zaidel].json index 1dbbcf89..769092ac 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest013_Zaidel].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest013_Zaidel].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3High].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3High].json index faf80b18..f6b91f10 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3High].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3High].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3High_mfusg].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3High_mfusg].json index a771d5d9..2d2c1569 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3High_mfusg].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3High_mfusg].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3Low].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3Low].json index 8da8e95e..f4a5de2a 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3Low].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3Low].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3Low_MAW].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3Low_MAW].json index a8a6e692..3120e348 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3Low_MAW].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3Low_MAW].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3Low_MD_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3Low_MD_dev].json index 8a8facc1..55e62f14 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3Low_MD_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3Low_MD_dev].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3Low_RCM_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3Low_RCM_dev].json index 6b3f36d0..848a3af3 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3Low_RCM_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3Low_RCM_dev].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3Low_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3Low_dev].json index a1fffa0d..d579465b 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3Low_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest014_NWTP3Low_dev].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest015_KeatingLike-xt3d-rhs].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest015_KeatingLike-xt3d-rhs].json index 6daebd8d..f8113217 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest015_KeatingLike-xt3d-rhs].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest015_KeatingLike-xt3d-rhs].json @@ -129,8 +129,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest015_KeatingLike-xt3d].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest015_KeatingLike-xt3d].json index 550a9e33..b3df7d57 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest015_KeatingLike-xt3d].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest015_KeatingLike-xt3d].json @@ -129,8 +129,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest015_KeatingLike].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest015_KeatingLike].json index 9761d14b..1ec8ea08 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest015_KeatingLike].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest015_KeatingLike].json @@ -128,8 +128,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest015_KeatingLike_disu].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest015_KeatingLike_disu].json index 0d02368e..37d6a2de 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest015_KeatingLike_disu].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest015_KeatingLike_disu].json @@ -134,8 +134,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest015_KeatingLike_disu_mfusg].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest015_KeatingLike_disu_mfusg].json index caa20ff5..c55de92e 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest015_KeatingLike_disu_mfusg].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest015_KeatingLike_disu_mfusg].json @@ -136,8 +136,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest016_Keating].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest016_Keating].json index 84dc1d91..f403dd07 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest016_Keating].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest016_Keating].json @@ -196,8 +196,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest016_Keating_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest016_Keating_dev].json index 1815c5b0..8c16aa09 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest016_Keating_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest016_Keating_dev].json @@ -196,8 +196,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest016_Keating_disu_250].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest016_Keating_disu_250].json index 6205d351..32fd4adb 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest016_Keating_disu_250].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest016_Keating_disu_250].json @@ -154,8 +154,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest016_Keating_disu_250_xt3d].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest016_Keating_disu_250_xt3d].json index 5ffe9936..7748da81 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest016_Keating_disu_250_xt3d].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest016_Keating_disu_250_xt3d].json @@ -140,8 +140,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest016_Keating_disu_mfusg].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest016_Keating_disu_mfusg].json index c5156be1..5311b144 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest016_Keating_disu_mfusg].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest016_Keating_disu_mfusg].json @@ -147,8 +147,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest017_Crinkle].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest017_Crinkle].json index 21eda6f2..0cbd0307 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest017_Crinkle].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest017_Crinkle].json @@ -205,11 +205,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " steady-state", + " STEADY-STATE", "END PERIOD 1", "", "BEGIN PERIOD 2", - " transient", + " TRANSIENT", "END PERIOD 2" ], "mfsim.nam": [ @@ -228,8 +228,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest019_VilhelmsenGC].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest019_VilhelmsenGC].json index 9961a05d..39fc8488 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest019_VilhelmsenGC].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest019_VilhelmsenGC].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 parent.ims PARENT", " MXITER 1", + " IMS6 parent.ims PARENT", "END SOLUTIONGROUP 1" ], "parent.dis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest019_VilhelmsenGF].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest019_VilhelmsenGF].json index b54cb533..a6e732b0 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest019_VilhelmsenGF].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest019_VilhelmsenGF].json @@ -182,8 +182,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 TM9_global_gv.ims PARENT", " MXITER 1", + " IMS6 TM9_global_gv.ims PARENT", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest019_VilhelmsenLGR].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest019_VilhelmsenLGR].json index 5285eb0e..66ea67fe 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest019_VilhelmsenLGR].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest019_VilhelmsenLGR].json @@ -296,8 +296,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 TM9_global.ims PARENT CHILD", " MXITER 1", + " IMS6 TM9_global.ims PARENT CHILD", "END SOLUTIONGROUP 1" ], "parent-child.gwfexg": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest019_VilhelmsenLGR_nr].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest019_VilhelmsenLGR_nr].json index 173b1fab..8ee6c726 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest019_VilhelmsenLGR_nr].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest019_VilhelmsenLGR_nr].json @@ -379,8 +379,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 TM9_global.ims PARENT CHILD", " MXITER 1", + " IMS6 TM9_global.ims PARENT CHILD", "END SOLUTIONGROUP 1" ], "parent-child.gwfexg": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NT_EI].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NT_EI].json index 9b2822da..eb5b4a68 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NT_EI].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NT_EI].json @@ -237,8 +237,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransientTS2].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransientTS2].json index 97a2d131..21f3abbf 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransientTS2].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransientTS2].json @@ -219,8 +219,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransientTS].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransientTS].json index 62464444..892e7695 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransientTS].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransientTS].json @@ -188,8 +188,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient].json index 8619a397..f7f02f0d 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient].json @@ -191,8 +191,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient_aniso].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient_aniso].json index 005534a6..417d4f17 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient_aniso].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient_aniso].json @@ -181,8 +181,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 mf6.ims6 mf6", " MXITER 1", + " IMS6 mf6.ims6 mf6", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient_constantMAW].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient_constantMAW].json index 0b2dabd9..0c28c91a 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient_constantMAW].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient_constantMAW].json @@ -180,8 +180,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient_cumcond].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient_cumcond].json index 16fb613d..76ac03eb 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient_cumcond].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient_cumcond].json @@ -167,8 +167,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient_cumcond_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient_cumcond_dev].json index 16fb613d..76ac03eb 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient_cumcond_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient_cumcond_dev].json @@ -167,8 +167,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient_thickstrt].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient_thickstrt].json index f4f333ee..5c032dd6 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient_thickstrt].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_NevilleTonkinTransient_thickstrt].json @@ -171,8 +171,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_mawconfined].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_mawconfined].json index d1f9b5e1..008d477d 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_mawconfined].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_mawconfined].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 test020_mawconfined.ims mawconf", " MXITER 1", + " IMS6 test020_mawconfined.ims mawconf", "END SOLUTIONGROUP 1" ], "test020_mawconfined.dis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_mawconfined_openclose].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_mawconfined_openclose].json index 96bf3bd3..99552e1c 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_mawconfined_openclose].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest020_mawconfined_openclose].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 test020_mawconfined.ims mawconf", " MXITER 1", + " IMS6 test020_mawconfined.ims mawconf", "END SOLUTIONGROUP 1" ], "test020_mawconfined.dis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest021_twri].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest021_twri].json index 02693db0..661a1132 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest021_twri].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest021_twri].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 twri.ims GWF_1", " MXITER 1", + " IMS6 twri.ims GWF_1", "END SOLUTIONGROUP 1" ], "twri.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest023_FlowingWell].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest023_FlowingWell].json index 30722afe..670a7ff5 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest023_FlowingWell].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest023_FlowingWell].json @@ -174,8 +174,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest024_Reilly].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest024_Reilly].json index 798be397..bdd9d6ad 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest024_Reilly].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest024_Reilly].json @@ -239,8 +239,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest024_Reilly_ext].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest024_Reilly_ext].json index 81064154..780e47b9 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest024_Reilly_ext].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest024_Reilly_ext].json @@ -240,8 +240,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest025_ConstantCV].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest025_ConstantCV].json index 70574769..10559d7f 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest025_ConstantCV].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest025_ConstantCV].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.dis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest025_ConstantCV_perched].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest025_ConstantCV_perched].json index cdb2c6ac..6616cb63 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest025_ConstantCV_perched].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest025_ConstantCV_perched].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.dis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest025_VariableCV].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest025_VariableCV].json index 9d187b51..59e8db25 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest025_VariableCV].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest025_VariableCV].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.dis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest025_Vertically_Staggered].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest025_Vertically_Staggered].json index affccf6d..2f1d3ec9 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest025_Vertically_Staggered].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest025_Vertically_Staggered].json @@ -157,8 +157,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flow.ims GWF_1", " MXITER 1", + " IMS6 flow.ims GWF_1", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest026_WellReduction].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest026_WellReduction].json index 10e1aa3e..a238f64e 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest026_WellReduction].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest026_WellReduction].json @@ -141,8 +141,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest027_TimeseriesTest].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest027_TimeseriesTest].json index 185c9dca..59ffe51c 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest027_TimeseriesTest].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest027_TimeseriesTest].json @@ -16,8 +16,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ @@ -300,11 +300,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " steady-state", + " STEADY-STATE", "END PERIOD 1", "", "BEGIN PERIOD 2", - " transient", + " TRANSIENT", "END PERIOD 2" ], "timeseriestest.wel": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest027_TimeseriesTest_idomain].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest027_TimeseriesTest_idomain].json index 315b9d4f..e350359c 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest027_TimeseriesTest_idomain].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest027_TimeseriesTest_idomain].json @@ -16,8 +16,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ @@ -304,11 +304,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " steady-state", + " STEADY-STATE", "END PERIOD 1", "", "BEGIN PERIOD 2", - " transient", + " TRANSIENT", "END PERIOD 2" ], "timeseriestest.wel": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr].json index 68930260..b94c1202 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr].json @@ -16,8 +16,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_mvr].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_mvr].json index 0457b88c..f34ccfec 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_mvr].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_mvr].json @@ -16,8 +16,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_mvr_openclose].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_mvr_openclose].json index 258ceac9..83c56e9e 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_mvr_openclose].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_mvr_openclose].json @@ -16,8 +16,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_rewet].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_rewet].json index d3468e9a..d33c4fbe 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_rewet].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_rewet].json @@ -195,8 +195,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 mf6.ims6 mf6", " MXITER 1", + " IMS6 mf6.ims6 mf6", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_rewet_drain].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_rewet_drain].json index 447cc04f..d20b2ab3 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_rewet_drain].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_rewet_drain].json @@ -241,8 +241,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 mf6.ims6 mf6", " MXITER 1", + " IMS6 mf6.ims6 mf6", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_rewet_nr].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_rewet_nr].json index c6ba9093..cf9fafc2 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_rewet_nr].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_rewet_nr].json @@ -205,8 +205,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 mf6.ims6 mf6", " MXITER 1", + " IMS6 mf6.ims6 mf6", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_rewet_simple].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_rewet_simple].json index dbadb6d8..a8c9a181 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_rewet_simple].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_rewet_simple].json @@ -208,8 +208,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 mf6.ims6 mf6", " MXITER 1", + " IMS6 mf6.ims6 mf6", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_simple].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_simple].json index f4cefaec..30bb2e9f 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_simple].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest028_sfr_simple].json @@ -274,8 +274,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 mf6.ims6 mf6", " MXITER 1", + " IMS6 mf6.ims6 mf6", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest029_lgr_parentchild].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest029_lgr_parentchild].json index 8a9780ea..a6f30bc1 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest029_lgr_parentchild].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest029_lgr_parentchild].json @@ -281,8 +281,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 PARENT_CHILD.ims PARENT CHILD", " MXITER 1", + " IMS6 PARENT_CHILD.ims PARENT CHILD", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest029_lgrsfr_parent].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest029_lgrsfr_parent].json index 73ea702d..5110c60d 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest029_lgrsfr_parent].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest029_lgrsfr_parent].json @@ -16,8 +16,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest029_lgrsfr_parent_hole].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest029_lgrsfr_parent_hole].json index 8821fe09..ead2ed11 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest029_lgrsfr_parent_hole].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest029_lgrsfr_parent_hole].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 sfr_hole.ims sfr_hole", " MXITER 1", + " IMS6 sfr_hole.ims sfr_hole", "END SOLUTIONGROUP 1" ], "sfr_hole.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest029_lgrsfr_parentchild].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest029_lgrsfr_parentchild].json index 75150863..46157a99 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest029_lgrsfr_parentchild].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest029_lgrsfr_parentchild].json @@ -355,8 +355,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 PARENT_CHILD.ims PARENT CHILD", " MXITER 1", + " IMS6 PARENT_CHILD.ims PARENT CHILD", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_col].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_col].json index 191dfd49..fdfdb2d6 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_col].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_col].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF", " MXITER 1", + " IMS6 model.ims GWF", "END SOLUTIONGROUP 1" ], "model.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_col_disu].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_col_disu].json index b171acc4..de73c542 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_col_disu].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_col_disu].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF", " MXITER 1", + " IMS6 model.ims GWF", "END SOLUTIONGROUP 1" ], "model.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_row].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_row].json index 303a1bd2..61aaa3e7 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_row].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_row].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF", " MXITER 1", + " IMS6 model.ims GWF", "END SOLUTIONGROUP 1" ], "model.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_row_disu].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_row_disu].json index 4648d004..b3f7238b 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_row_disu].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_row_disu].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF", " MXITER 1", + " IMS6 model.ims GWF", "END SOLUTIONGROUP 1" ], "model.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_xt3d].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_xt3d].json index 97fd829b..4ca819cd 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_xt3d].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_xt3d].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF", " MXITER 1", + " IMS6 model.ims GWF", "END SOLUTIONGROUP 1" ], "model.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_xt3d_disu].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_xt3d_disu].json index e2dec8f7..f3be99bd 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_xt3d_disu].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest030_hani_xt3d_disu].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF", " MXITER 1", + " IMS6 model.ims GWF", "END SOLUTIONGROUP 1" ], "model.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest032_sfr].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest032_sfr].json index c7818c88..023ed452 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest032_sfr].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest032_sfr].json @@ -16,8 +16,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest033_wtdecay].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest033_wtdecay].json index 96cb8439..23903f98 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest033_wtdecay].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest033_wtdecay].json @@ -19,8 +19,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.ims": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest034_nwtp2].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest034_nwtp2].json index c266ab09..1915336d 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest034_nwtp2].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest034_nwtp2].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 test034_nwtp2.ims test034_nwtp2", " MXITER 1", + " IMS6 test034_nwtp2.ims test034_nwtp2", "END SOLUTIONGROUP 1" ], "test034_nwtp2.dis": [ @@ -189,7 +189,7 @@ "END GRIDDATA", "", "BEGIN PERIOD 4", - " steady-state", + " STEADY-STATE", "END PERIOD 4" ], "test034_nwtp2.tdis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest034_nwtp2_1d].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest034_nwtp2_1d].json index d60088b9..9340c852 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest034_nwtp2_1d].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest034_nwtp2_1d].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 test034_nwtp2.ims test034_nwtp2", " MXITER 1", + " IMS6 test034_nwtp2.ims test034_nwtp2", "END SOLUTIONGROUP 1" ], "test034_nwtp2.dis": [ @@ -199,7 +199,7 @@ "END GRIDDATA", "", "BEGIN PERIOD 4", - " steady-state", + " STEADY-STATE", "END PERIOD 4" ], "test034_nwtp2.tdis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest035_fhb].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest035_fhb].json index 7e5adaf3..206a6911 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest035_fhb].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest035_fhb].json @@ -208,8 +208,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 fhb2015.ims fhb2015", " MXITER 1", + " IMS6 fhb2015.ims fhb2015", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest036_twrihfb].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest036_twrihfb].json index 7f89db99..51338e05 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest036_twrihfb].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest036_twrihfb].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 twrihfb2015.ims twrihfb2015", " MXITER 1", + " IMS6 twrihfb2015.ims twrihfb2015", "END SOLUTIONGROUP 1" ], "twrihfb2015.dis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest036_twrihfb_5lay].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest036_twrihfb_5lay].json index 39a4ea9d..b4244eea 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest036_twrihfb_5lay].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest036_twrihfb_5lay].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 test036_twrihfb.ims twrihfb_5lay", " MXITER 1", + " IMS6 test036_twrihfb.ims twrihfb_5lay", "END SOLUTIONGROUP 1" ], "test036_twrihfb.dis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest036_twrihfb_lpf].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest036_twrihfb_lpf].json index cb07437f..0cc9cc89 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest036_twrihfb_lpf].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest036_twrihfb_lpf].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 test036_twrihfb.ims test036_twrihfb", " MXITER 1", + " IMS6 test036_twrihfb.ims test036_twrihfb", "END SOLUTIONGROUP 1" ], "test036_twrihfb.dis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest036_twrihfb_nr].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest036_twrihfb_nr].json index 3653cfa7..b7a6e821 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest036_twrihfb_nr].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest036_twrihfb_nr].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 test036_twrihfb_nr.ims twrihfb_nr", " MXITER 1", + " IMS6 test036_twrihfb_nr.ims twrihfb_nr", "END SOLUTIONGROUP 1" ], "test036_twrihfb_nr.dis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest036_twrihfb_openclose].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest036_twrihfb_openclose].json index 15d9e19e..2d9ab004 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest036_twrihfb_openclose].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest036_twrihfb_openclose].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 twrihfb2015.ims twrihfb2015", " MXITER 1", + " IMS6 twrihfb2015.ims twrihfb2015", "END SOLUTIONGROUP 1" ], "twrihfb2015.chd.per1.ref": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest037_mfcp3].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest037_mfcp3].json index cb3b218b..bddbba67 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest037_mfcp3].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest037_mfcp3].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 test037.ims test037", " MXITER 1", + " IMS6 test037.ims test037", "END SOLUTIONGROUP 1" ], "test037.dis": [ @@ -168,15 +168,15 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " STEADY-STATE", + " STEADY-STATE", "END PERIOD 1", "", "BEGIN PERIOD 2", - " TRANSIENT", + " TRANSIENT", "END PERIOD 2", "", "BEGIN PERIOD 3", - " STEADY-STATE", + " STEADY-STATE", "END PERIOD 3" ], "test037.tdis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest038_idomain].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest038_idomain].json index 173c7ca4..0b7ab670 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest038_idomain].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest038_idomain].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF", " MXITER 1", + " IMS6 model.ims GWF", "END SOLUTIONGROUP 1" ], "model.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest041_flowdivert].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest041_flowdivert].json index d75eafb7..e7f0c579 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest041_flowdivert].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest041_flowdivert].json @@ -138,8 +138,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flowdivert.ims GWF_1", " MXITER 1", + " IMS6 flowdivert.ims GWF_1", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest041_flowdivert_mfusg].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest041_flowdivert_mfusg].json index f77cedc7..81a113aa 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest041_flowdivert_mfusg].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest041_flowdivert_mfusg].json @@ -137,8 +137,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flowdivert.ims GWF_1", " MXITER 1", + " IMS6 flowdivert.ims GWF_1", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest041_flowdivert_nr].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest041_flowdivert_nr].json index 93a39d18..ab8d0550 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest041_flowdivert_nr].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest041_flowdivert_nr].json @@ -135,8 +135,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flowdivert.ims GWF_1", " MXITER 1", + " IMS6 flowdivert.ims GWF_1", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest041_flowdivert_nwt_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest041_flowdivert_nwt_dev].json index fd5b73b6..699b7086 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest041_flowdivert_nwt_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest041_flowdivert_nwt_dev].json @@ -137,8 +137,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 flowdivert.ims GWF_1", " MXITER 1", + " IMS6 flowdivert.ims GWF_1", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_dev].json index dc2f365a..98d96d80 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_dev].json @@ -192,8 +192,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lake0.ims lake0", " MXITER 1", + " IMS6 lake0.ims lake0", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedh].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedh].json index 81cbbfce..37199995 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedh].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedh].json @@ -278,8 +278,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lake0_embedded.ims lake0_e", " MXITER 1", + " IMS6 lake0_embedded.ims lake0_e", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedh_conf].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedh_conf].json index 1d820cf0..654e773c 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedh_conf].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedh_conf].json @@ -285,8 +285,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lake0_embedded.ims lake0_e", " MXITER 1", + " IMS6 lake0_embedded.ims lake0_e", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedh_openclose].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedh_openclose].json index ef9707cc..1a94a454 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedh_openclose].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedh_openclose].json @@ -293,8 +293,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lake0_embedded.ims lake0_e", " MXITER 1", + " IMS6 lake0_embedded.ims lake0_e", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedv].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedv].json index 15611663..d0ef03cd 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedv].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedv].json @@ -284,8 +284,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lake0_embedded.ims lake0_e", " MXITER 1", + " IMS6 lake0_embedded.ims lake0_e", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedv_conf].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedv_conf].json index 9788742a..b81ba084 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedv_conf].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedv_conf].json @@ -284,8 +284,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lake0_embedded.ims lake0_e", " MXITER 1", + " IMS6 lake0_embedded.ims lake0_e", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedv_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedv_dev].json index 15611663..d0ef03cd 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedv_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest042_lake0_embeddedv_dev].json @@ -284,8 +284,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lake0_embedded.ims lake0_e", " MXITER 1", + " IMS6 lake0_embedded.ims lake0_e", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest043_drylake_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest043_drylake_dev].json index 521ce4d9..2dbcfe31 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest043_drylake_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest043_drylake_dev].json @@ -209,8 +209,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 drylake.ims ls", " MXITER 1", + " IMS6 drylake.ims ls", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest044_lakebotfill_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest044_lakebotfill_dev].json index d9b58d14..67fef55c 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest044_lakebotfill_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest044_lakebotfill_dev].json @@ -231,8 +231,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lbf.ims lbf", " MXITER 1", + " IMS6 lbf.ims lbf", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss].json index 01fa63db..2d1b5734 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss].json @@ -216,8 +216,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lakeex1b.ims lakeex1b", " MXITER 1", + " IMS6 lakeex1b.ims lakeex1b", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_1layer_alt_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_1layer_alt_dev].json index 8b534a2a..98467745 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_1layer_alt_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_1layer_alt_dev].json @@ -203,8 +203,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lakeex1b_1layerb.ims lakeex1b_1layerb", " MXITER 1", + " IMS6 lakeex1b_1layerb.ims lakeex1b_1layerb", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_1layer_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_1layer_dev].json index 4997db74..1ebd521e 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_1layer_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_1layer_dev].json @@ -221,8 +221,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lakeex1b_1layer.ims lakeex1b_1layer", " MXITER 1", + " IMS6 lakeex1b_1layer.ims lakeex1b_1layer", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_1layer_thickstrt_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_1layer_thickstrt_dev].json index b3db60b7..41fbee5a 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_1layer_thickstrt_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_1layer_thickstrt_dev].json @@ -220,8 +220,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lakeex1b_1layerc.ims lakeex1b_1layerc", " MXITER 1", + " IMS6 lakeex1b_1layerc.ims lakeex1b_1layerc", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_dev].json index eb31db40..03cb4065 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_dev].json @@ -216,8 +216,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lakeex1b.ims lakeex1b", " MXITER 1", + " IMS6 lakeex1b.ims lakeex1b", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_none_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_none_dev].json index 89de8fa1..959f0a28 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_none_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_none_dev].json @@ -216,8 +216,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lakeex1b.ims lakeex1b", " MXITER 1", + " IMS6 lakeex1b.ims lakeex1b", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_table_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_table_dev].json index 24baba6b..db211441 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_table_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1ss_table_dev].json @@ -229,8 +229,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lakeex1b.ims lakeex1b", " MXITER 1", + " IMS6 lakeex1b.ims lakeex1b", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1tr_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1tr_dev].json index 91d69576..46c30c8b 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1tr_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1tr_dev].json @@ -258,8 +258,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lakeex1a.ims lakeex1a", " MXITER 1", + " IMS6 lakeex1a.ims lakeex1a", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1tr_nr].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1tr_nr].json index fd245123..2fd7fe83 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1tr_nr].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake1tr_nr].json @@ -244,8 +244,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lakeex1a.ims lakeex1a", " MXITER 1", + " IMS6 lakeex1a.ims lakeex1a", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_dev].json index 9afba209..08c7342c 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_dev].json @@ -389,8 +389,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lakeex2a.ims lakeex2a", " MXITER 1", + " IMS6 lakeex2a.ims lakeex2a", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_il_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_il_dev].json index 9655ac45..211f5147 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_il_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_il_dev].json @@ -240,8 +240,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lakeex2a.ims lakeex2a", " MXITER 1", + " IMS6 lakeex2a.ims lakeex2a", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_nr].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_nr].json index b811e2c7..9aad09a6 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_nr].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_nr].json @@ -343,8 +343,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lakeex2a.ims lakeex2a", " MXITER 1", + " IMS6 lakeex2a.ims lakeex2a", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_xsfra_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_xsfra_dev].json index 1246b469..9405590e 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_xsfra_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_xsfra_dev].json @@ -288,8 +288,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lakeex2a.ims lakeex2a", " MXITER 1", + " IMS6 lakeex2a.ims lakeex2a", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_xsfrb_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_xsfrb_dev].json index 695a011b..7b0362fd 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_xsfrb_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_xsfrb_dev].json @@ -287,8 +287,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lakeex2a.ims lakeex2a", " MXITER 1", + " IMS6 lakeex2a.ims lakeex2a", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_xsfrc_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_xsfrc_dev].json index 5cfb52de..b6ffcc6f 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_xsfrc_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_xsfrc_dev].json @@ -285,8 +285,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lakeex2a.ims lakeex2a", " MXITER 1", + " IMS6 lakeex2a.ims lakeex2a", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_xsfrd_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_xsfrd_dev].json index 3caed392..df2dfa2e 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_xsfrd_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_xsfrd_dev].json @@ -286,8 +286,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lakeex2a.ims lakeex2a", " MXITER 1", + " IMS6 lakeex2a.ims lakeex2a", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_xsfre_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_xsfre_dev].json index 67e857e5..7b701d02 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_xsfre_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake2tr_xsfre_dev].json @@ -308,8 +308,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lakeex2a.ims lakeex2a", " MXITER 1", + " IMS6 lakeex2a.ims lakeex2a", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss].json index 4607ba42..759bdbc6 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss].json @@ -223,8 +223,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lakeex4.ims lakeex4", " MXITER 1", + " IMS6 lakeex4.ims lakeex4", "END SOLUTIONGROUP 1" ], "rch.obs": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss_cl_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss_cl_dev].json index 4be1577d..48122f54 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss_cl_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss_cl_dev].json @@ -222,8 +222,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lakeex4.ims lakeex4", " MXITER 1", + " IMS6 lakeex4.ims lakeex4", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss_dev].json index 4607ba42..759bdbc6 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss_dev].json @@ -223,8 +223,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lakeex4.ims lakeex4", " MXITER 1", + " IMS6 lakeex4.ims lakeex4", "END SOLUTIONGROUP 1" ], "rch.obs": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss_il_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss_il_dev].json index aa84ff4e..0ccc8165 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss_il_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss_il_dev].json @@ -221,8 +221,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lakeex4_il.ims lakeex4", " MXITER 1", + " IMS6 lakeex4_il.ims lakeex4", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss_nr_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss_nr_dev].json index 27e2af0d..09482b1c 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss_nr_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss_nr_dev].json @@ -223,8 +223,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lakeex4.ims lakeex4", " MXITER 1", + " IMS6 lakeex4.ims lakeex4", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss_nr_embedded].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss_nr_embedded].json index 4826baac..af770c8b 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss_nr_embedded].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest045_lake4ss_nr_embedded].json @@ -262,8 +262,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 lakeex4.ims lakeex4", " MXITER 1", + " IMS6 lakeex4.ims lakeex4", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest046_periodic_bc].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest046_periodic_bc].json index 2e6f89a0..bf708d0b 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest046_periodic_bc].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest046_periodic_bc].json @@ -16,8 +16,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 pbc.ims pbc", " MXITER 1", + " IMS6 pbc.ims pbc", "END SOLUTIONGROUP 1" ], "pbc.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest046_periodic_bc_openclose].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest046_periodic_bc_openclose].json index fb7a1cba..626909b2 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest046_periodic_bc_openclose].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest046_periodic_bc_openclose].json @@ -16,8 +16,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 pbc.ims pbc", " MXITER 1", + " IMS6 pbc.ims pbc", "END SOLUTIONGROUP 1" ], "pbc.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest048_lgr3d_conf].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest048_lgr3d_conf].json index 0b0ee4de..d9102b68 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest048_lgr3d_conf].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest048_lgr3d_conf].json @@ -99,8 +99,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 simulation.ims parent child", " MXITER 1", + " IMS6 simulation.ims parent child", "END SOLUTIONGROUP 1" ], "parent.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest048_lgr3d_unconfB].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest048_lgr3d_unconfB].json index 858b9ef2..bcc2452c 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest048_lgr3d_unconfB].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest048_lgr3d_unconfB].json @@ -99,8 +99,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 simulation.ims parent child", " MXITER 1", + " IMS6 simulation.ims parent child", "END SOLUTIONGROUP 1" ], "parent.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest048_lgr3d_unconfC].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest048_lgr3d_unconfC].json index 80b3292d..70705e9b 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest048_lgr3d_unconfC].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest048_lgr3d_unconfC].json @@ -99,8 +99,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 simulation.ims parent child", " MXITER 1", + " IMS6 simulation.ims parent child", "END SOLUTIONGROUP 1" ], "parent.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest048_lgr3d_unconfD].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest048_lgr3d_unconfD].json index 74458668..2f6bc74d 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest048_lgr3d_unconfD].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest048_lgr3d_unconfD].json @@ -98,8 +98,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 simulation.ims parent child", " MXITER 1", + " IMS6 simulation.ims parent child", "END SOLUTIONGROUP 1" ], "parent.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest048_lgr3d_unconf].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest048_lgr3d_unconf].json index 1d2069b3..75b8bfc8 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest048_lgr3d_unconf].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest048_lgr3d_unconf].json @@ -99,8 +99,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 simulation.ims parent child", " MXITER 1", + " IMS6 simulation.ims parent child", "END SOLUTIONGROUP 1" ], "parent.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest049_gwfexgrewet].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest049_gwfexgrewet].json index 3919bd1e..9ffcc9f4 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest049_gwfexgrewet].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest049_gwfexgrewet].json @@ -19,8 +19,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 simulation.ims Model_01 Model_02 Model_03", " MXITER 1", + " IMS6 simulation.ims Model_01 Model_02 Model_03", "END SOLUTIONGROUP 1" ], "model.tdis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest050_circle_island].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest050_circle_island].json index 91c3d5ee..8c72c112 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest050_circle_island].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest050_circle_island].json @@ -146,8 +146,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 ci.ims CI", " MXITER 1", + " IMS6 ci.ims CI", "END SOLUTIONGROUP 1" ], "rech.dat": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp2TS].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp2TS].json index dfe9e7ee..40301d64 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp2TS].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp2TS].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 uzfp2.ims uzfp2", " MXITER 1", + " IMS6 uzfp2.ims uzfp2", "END SOLUTIONGROUP 1" ], "uzfp2.dis": [ @@ -207,11 +207,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " STEADY-STATE", + " STEADY-STATE", "END PERIOD 1", "", "BEGIN PERIOD 2", - " TRANSIENT", + " TRANSIENT", "END PERIOD 2" ], "uzfp2.tdis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp2].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp2].json index fb50e970..f28f54d1 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp2].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp2].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 uzfp2.ims uzfp2", " MXITER 1", + " IMS6 uzfp2.ims uzfp2", "END SOLUTIONGROUP 1" ], "uzfp2.dis": [ @@ -207,11 +207,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " STEADY-STATE", + " STEADY-STATE", "END PERIOD 1", "", "BEGIN PERIOD 2", - " TRANSIENT", + " TRANSIENT", "END PERIOD 2" ], "uzfp2.tdis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp2_mvr].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp2_mvr].json index db3bbd7f..ae7b633e 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp2_mvr].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp2_mvr].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 uzfp2_mvr.ims uzfp2_mvr", " MXITER 1", + " IMS6 uzfp2_mvr.ims uzfp2_mvr", "END SOLUTIONGROUP 1" ], "uzfp2_mvr.dis": [ @@ -336,11 +336,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " STEADY-STATE", + " STEADY-STATE", "END PERIOD 1", "", "BEGIN PERIOD 2", - " TRANSIENT", + " TRANSIENT", "END PERIOD 2" ], "uzfp2_mvr.tdis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp2_nouzf].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp2_nouzf].json index a1b30e5c..3aff2f29 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp2_nouzf].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp2_nouzf].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 uzfp2_nouzf.ims uzfp2_nouzf", " MXITER 1", + " IMS6 uzfp2_nouzf.ims uzfp2_nouzf", "END SOLUTIONGROUP 1" ], "uzfp2_nouzf.dis": [ @@ -291,11 +291,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " STEADY-STATE", + " STEADY-STATE", "END PERIOD 1", "", "BEGIN PERIOD 2", - " TRANSIENT", + " TRANSIENT", "END PERIOD 2" ], "uzfp2_nouzf.tdis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp2_openclose].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp2_openclose].json index 38112a42..c72cb73e 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp2_openclose].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp2_openclose].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 uzfp2.ims uzfp2", " MXITER 1", + " IMS6 uzfp2.ims uzfp2", "END SOLUTIONGROUP 1" ], "uzfp2.dis": [ @@ -218,11 +218,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " STEADY-STATE", + " STEADY-STATE", "END PERIOD 1", "", "BEGIN PERIOD 2", - " TRANSIENT", + " TRANSIENT", "END PERIOD 2" ], "uzfp2.tdis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_aeET_lakmvr_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_aeET_lakmvr_dev].json index 971c897d..e7d957a8 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_aeET_lakmvr_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_aeET_lakmvr_dev].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 uzfp3_lakmvr.ims uzfp3_lakmvr", " MXITER 1", + " IMS6 uzfp3_lakmvr.ims uzfp3_lakmvr", "END SOLUTIONGROUP 1" ], "uzfp3_lakmvr.dis": [ @@ -366,11 +366,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " STEADY-STATE", + " STEADY-STATE", "END PERIOD 1", "", "BEGIN PERIOD 2", - " TRANSIENT", + " TRANSIENT", "END PERIOD 2" ], "uzfp3_lakmvr.tdis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_lakmvr_2uzfmodels_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_lakmvr_2uzfmodels_dev].json index 15f5a8b9..453eb8e1 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_lakmvr_2uzfmodels_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_lakmvr_2uzfmodels_dev].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 uzfp3_lakmvr.ims uzfp3_lakmvr", " MXITER 1", + " IMS6 uzfp3_lakmvr.ims uzfp3_lakmvr", "END SOLUTIONGROUP 1" ], "uzfp3_lakmvr.dis": [ @@ -368,11 +368,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " STEADY-STATE", + " STEADY-STATE", "END PERIOD 1", "", "BEGIN PERIOD 2", - " TRANSIENT", + " TRANSIENT", "END PERIOD 2" ], "uzfp3_lakmvr.tdis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_lakmvr_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_lakmvr_dev].json index f5ca2ab1..b26c01a8 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_lakmvr_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_lakmvr_dev].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 uzfp3_lakmvr.ims uzfp3_lakmvr", " MXITER 1", + " IMS6 uzfp3_lakmvr.ims uzfp3_lakmvr", "END SOLUTIONGROUP 1" ], "uzfp3_lakmvr.dis": [ @@ -366,11 +366,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " STEADY-STATE", + " STEADY-STATE", "END PERIOD 1", "", "BEGIN PERIOD 2", - " TRANSIENT", + " TRANSIENT", "END PERIOD 2" ], "uzfp3_lakmvr.tdis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_lakmvr_nouzf_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_lakmvr_nouzf_dev].json index bdd0d0c3..1553deb6 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_lakmvr_nouzf_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_lakmvr_nouzf_dev].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 uzfp3_lakmvr_nouzf.ims lakmvr_nouzf", " MXITER 1", + " IMS6 uzfp3_lakmvr_nouzf.ims lakmvr_nouzf", "END SOLUTIONGROUP 1" ], "uzfp3_lakmvr_nouzf.dis": [ @@ -357,11 +357,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " STEADY-STATE", + " STEADY-STATE", "END PERIOD 1", "", "BEGIN PERIOD 2", - " TRANSIENT", + " TRANSIENT", "END PERIOD 2" ], "uzfp3_lakmvr_nouzf.tdis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_lakmvr_v2_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_lakmvr_v2_dev].json index 0b52c6b3..99e8552a 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_lakmvr_v2_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_lakmvr_v2_dev].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 uzfp3_lakmvr_v2.ims uzfp3_lakmvr", " MXITER 1", + " IMS6 uzfp3_lakmvr_v2.ims uzfp3_lakmvr", "END SOLUTIONGROUP 1" ], "sfr.obs": [ @@ -438,11 +438,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " STEADY-STATE", + " STEADY-STATE", "END PERIOD 1", "", "BEGIN PERIOD 2", - " TRANSIENT", + " TRANSIENT", "END PERIOD 2" ], "uzfp3_lakmvr_v2.tdis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_wellakmvr_v2].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_wellakmvr_v2].json index fe4f09c5..46e0f07c 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_wellakmvr_v2].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest051_uzfp3_wellakmvr_v2].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 uzfp3_lakmvr_v2.ims uzfp3_lakmvr", " MXITER 1", + " IMS6 uzfp3_lakmvr_v2.ims uzfp3_lakmvr", "END SOLUTIONGROUP 1" ], "sfr.obs": [ @@ -449,11 +449,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " STEADY-STATE", + " STEADY-STATE", "END PERIOD 1", "", "BEGIN PERIOD 2", - " TRANSIENT", + " TRANSIENT", "END PERIOD 2" ], "uzfp3_lakmvr_v2.tdis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest052_uzf_3col].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest052_uzf_3col].json index 5e40ffea..24b6e097 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest052_uzf_3col].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest052_uzf_3col].json @@ -185,8 +185,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 mf6.ims mf6", " MXITER 1", + " IMS6 mf6.ims mf6", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest053_npf-a].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest053_npf-a].json index 419e18a1..3a70fa72 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest053_npf-a].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest053_npf-a].json @@ -195,8 +195,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 mf6.ims mf6", " MXITER 1", + " IMS6 mf6.ims mf6", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest053_npf-a_mfusg].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest053_npf-a_mfusg].json index afcae08c..5d752a31 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest053_npf-a_mfusg].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest053_npf-a_mfusg].json @@ -197,8 +197,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 mf6.ims mf6", " MXITER 1", + " IMS6 mf6.ims mf6", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest053_npf-b].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest053_npf-b].json index 3ac3ac46..23a9862e 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest053_npf-b].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest053_npf-b].json @@ -198,8 +198,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 mf6.ims mf6", " MXITER 1", + " IMS6 mf6.ims mf6", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest053_npf-b_mfusg].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest053_npf-b_mfusg].json index 5d7b5cd5..07d4efbd 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest053_npf-b_mfusg].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest053_npf-b_mfusg].json @@ -199,8 +199,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 mf6.ims mf6", " MXITER 1", + " IMS6 mf6.ims mf6", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest054_xt3d_whirlsA].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest054_xt3d_whirlsA].json index 5f900032..d2f6af9e 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest054_xt3d_whirlsA].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest054_xt3d_whirlsA].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest054_xt3d_whirlsB].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest054_xt3d_whirlsB].json index 1067ad46..29d96aa0 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest054_xt3d_whirlsB].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest054_xt3d_whirlsB].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest054_xt3d_whirlsC].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest054_xt3d_whirlsC].json index c26d242d..cc40ed94 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest054_xt3d_whirlsC].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest054_xt3d_whirlsC].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest055_xt3d_lvda-doc-test1].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest055_xt3d_lvda-doc-test1].json index c22dd48e..33d51a97 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest055_xt3d_lvda-doc-test1].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest055_xt3d_lvda-doc-test1].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.chd": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest056_mt3dms_usgs_gwtex_IR_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest056_mt3dms_usgs_gwtex_IR_dev].json index c63a3c72..f66f379b 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest056_mt3dms_usgs_gwtex_IR_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest056_mt3dms_usgs_gwtex_IR_dev].json @@ -320,8 +320,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 mf6-gwt.ims m1", " MXITER 1", + " IMS6 mf6-gwt.ims m1", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest056_mt3dms_usgs_gwtex_dev].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest056_mt3dms_usgs_gwtex_dev].json index 5ce10ca7..79d9f0ec 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest056_mt3dms_usgs_gwtex_dev].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest056_mt3dms_usgs_gwtex_dev].json @@ -299,8 +299,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 mf6-gwt.ims m1", " MXITER 1", + " IMS6 mf6-gwt.ims m1", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest057_transientchd].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest057_transientchd].json index 5fc3e162..c603c1e2 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest057_transientchd].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest057_transientchd].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.dis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest059_mvlake_lak_ss].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest059_mvlake_lak_ss].json index 6e838c83..e3682764 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest059_mvlake_lak_ss].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest059_mvlake_lak_ss].json @@ -21,8 +21,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 mv.ims mv", " MXITER 1", + " IMS6 mv.ims mv", "END SOLUTIONGROUP 1" ], "mv.dis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest061_csub_holly].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest061_csub_holly].json index ed22b636..2cb551db 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest061_csub_holly].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest061_csub_holly].json @@ -237,7 +237,7 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " TRANSIENT", + " TRANSIENT", "END PERIOD 1" ], "holly.tdis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest061_csub_jacob].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest061_csub_jacob].json index 7f132ae3..ab3fb740 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest061_csub_jacob].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest061_csub_jacob].json @@ -185,11 +185,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " STEADY-STATE", + " STEADY-STATE", "END PERIOD 1", "", "BEGIN PERIOD 2", - " TRANSIENT", + " TRANSIENT", "END PERIOD 2" ], "fig4_base.tdis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest100_ss_ic].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest100_ss_ic].json index 4b0dfd89..6bbfc3e7 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest100_ss_ic].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest100_ss_ic].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 test1ss_ic.ims test1ss_ic", " MXITER 1", + " IMS6 test1ss_ic.ims test1ss_ic", "END SOLUTIONGROUP 1" ], "test1ss_ic.dis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest101_fhb].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest101_fhb].json index 466e48d0..b095c6e3 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest101_fhb].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest101_fhb].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 test_fhb.ims test_fhb", " MXITER 1", + " IMS6 test_fhb.ims test_fhb", "END SOLUTIONGROUP 1" ], "test_fhb.dis": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest102_wel_mvr].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest102_wel_mvr].json index 80935221..06ee591d 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest102_wel_mvr].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest102_wel_mvr].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 welmvr.ims welmvr", " MXITER 1", + " IMS6 welmvr.ims welmvr", "END SOLUTIONGROUP 1" ], "wel.obs": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest103_drn_mvr].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest103_drn_mvr].json index ea1dbeea..614cde2b 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest103_drn_mvr].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest103_drn_mvr].json @@ -226,8 +226,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 drnmvr.ims drnmvr", " MXITER 1", + " IMS6 drnmvr.ims drnmvr", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest104_riv_mvr].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest104_riv_mvr].json index e9259809..c097185b 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest104_riv_mvr].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest104_riv_mvr].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 rivmvr.ims rivmvr", " MXITER 1", + " IMS6 rivmvr.ims rivmvr", "END SOLUTIONGROUP 1" ], "riv.obs": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest105_ghb_mvr].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest105_ghb_mvr].json index 750048cd..902d3a68 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest105_ghb_mvr].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest105_ghb_mvr].json @@ -237,8 +237,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 ghbmvr.ims ghbmvr", " MXITER 1", + " IMS6 ghbmvr.ims ghbmvr", "END SOLUTIONGROUP 1" ] } diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest106_tsnodata].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest106_tsnodata].json index 4d640679..022b298c 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest106_tsnodata].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest106_tsnodata].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.dis": [ @@ -133,11 +133,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " steady-state", + " STEADY-STATE", "END PERIOD 1", "", "BEGIN PERIOD 2", - " transient", + " TRANSIENT", "END PERIOD 2" ], "model.wel": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest106_tsnodataalt_model].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest106_tsnodataalt_model].json index 7586b657..3170044d 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest106_tsnodataalt_model].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest106_tsnodataalt_model].json @@ -15,8 +15,8 @@ "END EXCHANGES", "", "BEGIN SOLUTIONGROUP 1", - " IMS6 model.ims GWF_1", " MXITER 1", + " IMS6 model.ims GWF_1", "END SOLUTIONGROUP 1" ], "model.dis": [ @@ -133,11 +133,11 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " steady-state", + " STEADY-STATE", "END PERIOD 1", "", "BEGIN PERIOD 2", - " transient", + " TRANSIENT", "END PERIOD 2" ], "model.wel": [ diff --git a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest205_gwtbuy-henrytidal].json b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest205_gwtbuy-henrytidal].json index 2506fb53..e3eb55b1 100644 --- a/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest205_gwtbuy-henrytidal].json +++ b/test/mf6/__snapshots__/test_mf6_io_roundtrip/test_roundtrip[mf6testtest205_gwtbuy-henrytidal].json @@ -8835,7 +8835,7 @@ "END GRIDDATA", "", "BEGIN PERIOD 1", - " TRANSIENT", + " TRANSIENT", "END PERIOD 1" ], "gwf_henry.wel": [ diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1000_751x751].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1000_751x751].json index 288b7593..12c9287f 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1000_751x751].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1000_751x751].json @@ -208,29 +208,6 @@ }, "simulation/GWF_1/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "steady-state" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "transient" - ] - }, - "2": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "steady-state" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 751, @@ -248,6 +225,11 @@ "ss": "float64[582025] 8e32b8808a7463a8", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient", + "2": "steady-state" + }, "sy": "float64[582025] d644f68bfd022132" }, "simulation/GWF_1/wel-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1000_751x751_confined].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1000_751x751_confined].json index 0d197595..701efc1a 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1000_751x751_confined].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1000_751x751_confined].json @@ -165,29 +165,6 @@ }, "simulation/GWF_1/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "steady-state" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "transient" - ] - }, - "2": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "steady-state" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 751, @@ -205,6 +182,11 @@ "ss": "float64[582025] d09d4b05e804b43f", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient", + "2": "steady-state" + }, "sy": "float64[582025] 8e32b8808a7463a8" }, "simulation/GWF_1/wel-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1003_MNW2_Fig28].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1003_MNW2_Fig28].json index ad938791..fd622d24 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1003_MNW2_Fig28].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1003_MNW2_Fig28].json @@ -404,22 +404,6 @@ }, "simulation/GWF_1/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "steady-state" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "transient" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 272, @@ -437,6 +421,10 @@ "ss": "float64[334560] a3e95325fc719a79", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[334560] ff9856b4091cd415" }, "simulation/GWF_1/wel-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1004_mvlake_lak_tr].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1004_mvlake_lak_tr].json index 29fda79e..ae25cf28 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1004_mvlake_lak_tr].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1004_mvlake_lak_tr].json @@ -410,22 +410,6 @@ }, "simulation/mv/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "STEADY-STATE" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 25, @@ -443,6 +427,10 @@ "ss": "float64[5000] a5b1f02513ab097d", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[5000] 34180ed3a46722b0" }, "simulation/mv/wel-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1004_mvlake_laksfr_tr].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1004_mvlake_laksfr_tr].json index b1192a2a..ba3bb02f 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1004_mvlake_laksfr_tr].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1004_mvlake_laksfr_tr].json @@ -502,22 +502,6 @@ }, "simulation/mv/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "STEADY-STATE" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 25, @@ -535,6 +519,10 @@ "ss": "float64[5000] a5b1f02513ab097d", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[5000] 34180ed3a46722b0" }, "simulation/mv/wel-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1005_secp].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1005_secp].json index eab38e8b..514484d7 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1005_secp].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6largetest1005_secp].json @@ -297,22 +297,6 @@ }, "simulation/secp_mf6/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "STEADY-STATE" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 275, @@ -330,6 +314,10 @@ "ss": "float64[572000] 311d924bb3073b74", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[572000] 95fb8ad05a2d4c9b" }, "simulation/secp_mf6/wel-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest001e_UZF_3layTS].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest001e_UZF_3layTS].json index 6359aa39..62585092 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest001e_UZF_3layTS].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest001e_UZF_3layTS].json @@ -233,22 +233,6 @@ }, "simulation/GWF_1/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "transient" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 10, @@ -266,6 +250,10 @@ "ss": "float64[30] 368c7d008c4c4635", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "0": "transient", + "1": "transient" + }, "sy": "float64[30] 3e2c7d397e7f2184" }, "simulation/GWF_1/uzf-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest001e_UZF_3lay].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest001e_UZF_3lay].json index 41a41de2..af916a75 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest001e_UZF_3lay].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest001e_UZF_3lay].json @@ -233,22 +233,6 @@ }, "simulation/GWF_1/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "transient" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 10, @@ -266,6 +250,10 @@ "ss": "float64[30] 368c7d008c4c4635", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "0": "transient", + "1": "transient" + }, "sy": "float64[30] 3e2c7d397e7f2184" }, "simulation/GWF_1/uzf-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest001e_UZF_TS].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest001e_UZF_TS].json index c53a1ccc..5c4ae55b 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest001e_UZF_TS].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest001e_UZF_TS].json @@ -231,22 +231,6 @@ }, "simulation/GWF_1/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "transient" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 3, @@ -264,6 +248,10 @@ "ss": "float64[9] 6468c106717f86c0", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "0": "transient", + "1": "transient" + }, "sy": "float64[9] e15e06c9d6bf7d5a" }, "simulation/GWF_1/uzf-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest001e_UZF_spring].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest001e_UZF_spring].json index b2519e55..7bbbc1f4 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest001e_UZF_spring].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest001e_UZF_spring].json @@ -185,22 +185,6 @@ }, "simulation/GWF_1/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "STEADY-STATE" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 10, @@ -218,6 +202,10 @@ "ss": "float64[10] acd25494c6811185", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[10] d20144b7dfc27b2d" }, "simulation/GWF_1/uzf-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest001e_noUZF_3lay].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest001e_noUZF_3lay].json index 87e2ec9c..b57375eb 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest001e_noUZF_3lay].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest001e_noUZF_3lay].json @@ -241,22 +241,6 @@ }, "simulation/GWF_1/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "transient" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 10, @@ -274,6 +258,10 @@ "ss": "float64[30] 368c7d008c4c4635", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "0": "transient", + "1": "transient" + }, "sy": "float64[30] 3e2c7d397e7f2184" }, "simulation/ims-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest003_gwfs_tr].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest003_gwfs_tr].json index 8fc2e1e5..352de7cc 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest003_gwfs_tr].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest003_gwfs_tr].json @@ -275,22 +275,6 @@ }, "simulation/GWF_1/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "steady-state" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "transient" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 10, @@ -308,6 +292,10 @@ "ss": "float64[100] e25af2e25882f6f1", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[100] 73329cb7671df4b9" }, "simulation/ims-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest005_advgw_tidal].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest005_advgw_tidal].json index 31a2a207..8991237d 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest005_advgw_tidal].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest005_advgw_tidal].json @@ -1010,22 +1010,6 @@ }, "simulation/GWF_1/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "STEADY-STATE" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 10, @@ -1043,6 +1027,10 @@ "ss": "float64[450] b1a3de0b97dd99ab", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[450] 450f72f145d4702a" }, "simulation/ims-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest007_75x75].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest007_75x75].json index d270bede..cac64bbe 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest007_75x75].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest007_75x75].json @@ -247,29 +247,6 @@ }, "simulation/mf6/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "STEADY-STATE" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - }, - "2": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "STEADY-STATE" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 75, @@ -287,6 +264,11 @@ "ss": "float64[5625] 5e86ebb37e27d457", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient", + "2": "steady-state" + }, "sy": "float64[5625] 8445856c9bc63878" }, "simulation/mf6/wel-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest007_75x75_confined].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest007_75x75_confined].json index 57dc7714..d055308d 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest007_75x75_confined].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest007_75x75_confined].json @@ -247,29 +247,6 @@ }, "simulation/mf6/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "STEADY-STATE" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - }, - "2": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "STEADY-STATE" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 75, @@ -287,6 +264,11 @@ "ss": "float64[5625] c138bff052b010b2", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient", + "2": "steady-state" + }, "sy": "float64[5625] 5e86ebb37e27d457" }, "simulation/mf6/wel-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest017_Crinkle].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest017_Crinkle].json index 6c36918f..30a0be85 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest017_Crinkle].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest017_Crinkle].json @@ -252,22 +252,6 @@ }, "simulation/GWF_1/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "steady-state" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "transient" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 80, @@ -285,6 +269,10 @@ "ss": "float64[12800] e84e197d1b7532bc", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[12800] 693dda47a032acca" }, "simulation/ims-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest027_TimeseriesTest].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest027_TimeseriesTest].json index e6d86029..67ae6e40 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest027_TimeseriesTest].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest027_TimeseriesTest].json @@ -346,22 +346,6 @@ }, "simulation/GWF_1/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "steady-state" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "transient" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 51, @@ -379,6 +363,10 @@ "ss": "float64[5202] d09b21c36336b0ee", "ss_confined_only": true, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[5202] ff6ea1f11dba6b1d" }, "simulation/GWF_1/wel-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest027_TimeseriesTest_idomain].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest027_TimeseriesTest_idomain].json index 81dfc622..9057de4a 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest027_TimeseriesTest_idomain].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest027_TimeseriesTest_idomain].json @@ -346,22 +346,6 @@ }, "simulation/GWF_1/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "steady-state" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "transient" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 51, @@ -379,6 +363,10 @@ "ss": "float64[5202] d09b21c36336b0ee", "ss_confined_only": true, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[5202] ff6ea1f11dba6b1d" }, "simulation/GWF_1/wel-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest034_nwtp2].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest034_nwtp2].json index 148601da..224ce0e8 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest034_nwtp2].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest034_nwtp2].json @@ -349,15 +349,6 @@ }, "simulation/test034_nwtp2/sto": { "__type__": "Sto", - "_stress_period_data": { - "3": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "steady-state" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 40, @@ -375,6 +366,9 @@ "ss": "float64[22400] 3f0dd39315bebd22", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "3": "steady-state" + }, "sy": "float64[22400] 276974ce10de853f" } } diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest034_nwtp2_1d].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest034_nwtp2_1d].json index 926dbc2d..dd2f366b 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest034_nwtp2_1d].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest034_nwtp2_1d].json @@ -430,15 +430,6 @@ }, "simulation/test034_nwtp2/sto": { "__type__": "Sto", - "_stress_period_data": { - "3": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "steady-state" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 1, @@ -456,6 +447,9 @@ "ss": "float64[14] 743b3645024812a1", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "3": "steady-state" + }, "sy": "float64[14] 1ee0d13d3277a6f6" } } diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest037_mfcp3].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest037_mfcp3].json index 2f7827c4..8c283c96 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest037_mfcp3].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest037_mfcp3].json @@ -336,29 +336,6 @@ }, "simulation/test037/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "STEADY-STATE" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - }, - "2": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "STEADY-STATE" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 20, @@ -376,6 +353,11 @@ "ss": "float64[420] 547a0f20e08deac6", "ss_confined_only": true, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient", + "2": "steady-state" + }, "sy": "float64[420] c87c65842cbf5714" }, "simulation/test037/wel-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp2TS].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp2TS].json index 16f11f90..8294a527 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp2TS].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp2TS].json @@ -598,22 +598,6 @@ }, "simulation/uzfp2/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "STEADY-STATE" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 10, @@ -631,6 +615,10 @@ "ss": "float64[150] 5cc5e29ca9737a64", "ss_confined_only": true, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[150] 837f288590c22f6b" }, "simulation/uzfp2/wel-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp2].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp2].json index 8d669a4a..a4698dda 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp2].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp2].json @@ -465,22 +465,6 @@ }, "simulation/uzfp2/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "STEADY-STATE" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 10, @@ -498,6 +482,10 @@ "ss": "float64[150] 5cc5e29ca9737a64", "ss_confined_only": true, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[150] 837f288590c22f6b" }, "simulation/uzfp2/wel-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp2_mvr].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp2_mvr].json index 5838c892..96194064 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp2_mvr].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp2_mvr].json @@ -424,22 +424,6 @@ }, "simulation/uzfp2_mvr/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "STEADY-STATE" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 10, @@ -457,6 +441,10 @@ "ss": "float64[150] 5cc5e29ca9737a64", "ss_confined_only": true, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[150] 837f288590c22f6b" }, "simulation/uzfp2_mvr/wel-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp2_nouzf].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp2_nouzf].json index 23a255eb..9682e452 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp2_nouzf].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp2_nouzf].json @@ -379,22 +379,6 @@ }, "simulation/uzfp2_nouzf/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "STEADY-STATE" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 10, @@ -412,6 +396,10 @@ "ss": "float64[150] 5cc5e29ca9737a64", "ss_confined_only": true, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[150] 837f288590c22f6b" }, "simulation/uzfp2_nouzf/wel-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp2_openclose].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp2_openclose].json index 1e8d613d..50c16c28 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp2_openclose].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp2_openclose].json @@ -464,22 +464,6 @@ }, "simulation/uzfp2/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "STEADY-STATE" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 10, @@ -497,6 +481,10 @@ "ss": "float64[150] 5cc5e29ca9737a64", "ss_confined_only": true, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[150] 837f288590c22f6b" }, "simulation/uzfp2/wel-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_aeET_lakmvr_dev].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_aeET_lakmvr_dev].json index 3341a80d..996b66e9 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_aeET_lakmvr_dev].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_aeET_lakmvr_dev].json @@ -570,22 +570,6 @@ }, "simulation/uzfp3_lakmvr/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "STEADY-STATE" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 10, @@ -603,6 +587,10 @@ "ss": "float64[300] 19827a00e2b4e010", "ss_confined_only": true, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[300] 65156b101a71ecd0" }, "simulation/uzfp3_lakmvr/wel-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_lakmvr_2uzfmodels_dev].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_lakmvr_2uzfmodels_dev].json index 0d03ea3c..a0b30776 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_lakmvr_2uzfmodels_dev].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_lakmvr_2uzfmodels_dev].json @@ -615,22 +615,6 @@ }, "simulation/uzfp3_lakmvr/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "STEADY-STATE" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 10, @@ -648,6 +632,10 @@ "ss": "float64[300] 19827a00e2b4e010", "ss_confined_only": true, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[300] 65156b101a71ecd0" }, "simulation/uzfp3_lakmvr/wel-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_lakmvr_dev].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_lakmvr_dev].json index 60beb305..b3d6d153 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_lakmvr_dev].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_lakmvr_dev].json @@ -568,22 +568,6 @@ }, "simulation/uzfp3_lakmvr/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "STEADY-STATE" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 10, @@ -601,6 +585,10 @@ "ss": "float64[300] 19827a00e2b4e010", "ss_confined_only": true, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[300] 65156b101a71ecd0" }, "simulation/uzfp3_lakmvr/wel-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_lakmvr_nouzf_dev].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_lakmvr_nouzf_dev].json index 47b1f4d1..93440dbd 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_lakmvr_nouzf_dev].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_lakmvr_nouzf_dev].json @@ -576,22 +576,6 @@ }, "simulation/lakmvr_nouzf/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "STEADY-STATE" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 10, @@ -609,6 +593,10 @@ "ss": "float64[300] 19827a00e2b4e010", "ss_confined_only": true, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[300] 65156b101a71ecd0" }, "simulation/lakmvr_nouzf/wel-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_lakmvr_v2_dev].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_lakmvr_v2_dev].json index c8f35326..7cda84aa 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_lakmvr_v2_dev].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_lakmvr_v2_dev].json @@ -994,22 +994,6 @@ }, "simulation/uzfp3_lakmvr/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "STEADY-STATE" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 10, @@ -1027,6 +1011,10 @@ "ss": "float64[300] 19827a00e2b4e010", "ss_confined_only": true, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[300] 65156b101a71ecd0" } } diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_wellakmvr_v2].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_wellakmvr_v2].json index 70aa622c..ab9b758c 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_wellakmvr_v2].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest051_uzfp3_wellakmvr_v2].json @@ -1114,22 +1114,6 @@ }, "simulation/uzfp3_lakmvr/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "STEADY-STATE" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 10, @@ -1147,6 +1131,10 @@ "ss": "float64[300] 19827a00e2b4e010", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[300] 65156b101a71ecd0" } } diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest061_csub_holly].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest061_csub_holly].json index 278f5b83..fd1076b0 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest061_csub_holly].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest061_csub_holly].json @@ -469,15 +469,6 @@ }, "simulation/holly/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 1, @@ -495,6 +486,9 @@ "ss": "float64[14] 5c0168621a045c60", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "0": "transient" + }, "sy": "float64[14] 5c0168621a045c60" }, "simulation/ims-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest061_csub_jacob].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest061_csub_jacob].json index 19823709..96adb738 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest061_csub_jacob].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest061_csub_jacob].json @@ -354,22 +354,6 @@ }, "simulation/fig4_base/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "STEADY-STATE" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 35, @@ -387,6 +371,10 @@ "ss": "float64[105] 712afbf4bdf24b6f", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[105] 107c57480f9b04d7" }, "simulation/ims-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest106_tsnodata].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest106_tsnodata].json index 3dc5d2a7..11609dfd 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest106_tsnodata].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest106_tsnodata].json @@ -255,22 +255,6 @@ }, "simulation/GWF_1/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "steady-state" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "transient" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 20, @@ -288,6 +272,10 @@ "ss": "float64[800] b8e8a15f70c48199", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[800] 792547c5259dcbbf" }, "simulation/GWF_1/wel-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest106_tsnodataalt_model].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest106_tsnodataalt_model].json index 878fca08..94a6b6e0 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest106_tsnodataalt_model].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest106_tsnodataalt_model].json @@ -255,22 +255,6 @@ }, "simulation/GWF_1/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "steady-state" - ] - }, - "1": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "transient" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 20, @@ -288,6 +272,10 @@ "ss": "float64[800] b8e8a15f70c48199", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "0": "steady-state", + "1": "transient" + }, "sy": "float64[800] 792547c5259dcbbf" }, "simulation/GWF_1/wel-1": { diff --git a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest205_gwtbuy-henrytidal].json b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest205_gwtbuy-henrytidal].json index fc3a318b..56774a3a 100644 --- a/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest205_gwtbuy-henrytidal].json +++ b/test/mf6/__snapshots__/test_mf6_load_all_models/test_load_simulation[mf6testtest205_gwtbuy-henrytidal].json @@ -245,15 +245,6 @@ }, "simulation/gwf_henry/sto": { "__type__": "Sto", - "_stress_period_data": { - "0": { - "__table__": "StressPeriodData", - "n": 1, - "stress_period_data": [ - "TRANSIENT" - ] - } - }, "dims": { "ncelldim": 3, "ncol": 80, @@ -271,6 +262,9 @@ "ss": "float64[3200] 02e68636129d188b", "ss_confined_only": false, "storagecoefficient": false, + "stress_period_data": { + "0": "transient" + }, "sy": "float64[3200] 4a937098d0c2c954" }, "simulation/gwf_henry/wel-1": { diff --git a/test/mf6/test_mf6_codec.py b/test/mf6/test_mf6_codec.py index aed07e98..21a62a57 100644 --- a/test/mf6/test_mf6_codec.py +++ b/test/mf6/test_mf6_codec.py @@ -390,18 +390,18 @@ def test_dumps_sto(): sto = Sto( stress_period_data={ - 0: [("TRANSIENT",)], - 1: [("STEADY-STATE",)], - 2: [("TRANSIENT",)], + 0: "transient", + 1: "steady-state", + 2: "transient", } ) dumped = dumps(COMPONENT_CONVERTER.unstructure(sto)) print("STO dump:") print(dumped) - assert "BEGIN PERIOD 1\n TRANSIENT" in dumped - assert "BEGIN PERIOD 2\n STEADY-STATE" in dumped - assert "BEGIN PERIOD 3\n TRANSIENT" in dumped + assert "BEGIN PERIOD 1\n TRANSIENT" in dumped + assert "BEGIN PERIOD 2\n STEADY-STATE" in dumped + assert "BEGIN PERIOD 3\n TRANSIENT" in dumped assert dumped loaded = loads(dumped) @@ -2806,8 +2806,8 @@ def test_oc_period_string_int_keys(): pb_str = _period_blocks(oc_str) assert pb_int == pb_str - assert pb_int["period 1"]["period"] == [("SAVE", "BUDGET", "ALL")] - assert pb_int["period 2"]["period"] == [("SAVE", "BUDGET", "LAST")] + assert pb_int["period 1"]["stress_period_data"] == [("SAVE", "BUDGET", "ALL")] + assert pb_int["period 2"]["stress_period_data"] == [("SAVE", "BUDGET", "LAST")] # No fill-forward: period 3 was not specified so it produces no block. assert "period 3" not in pb_int @@ -2825,7 +2825,10 @@ def test_oc_period_wildcard_fillforward(): assert len(pb) == 4 for i in range(1, 5): - assert pb[f"period {i}"]["period"] == [("SAVE", "HEAD", "ALL"), ("SAVE", "BUDGET", "LAST")] + assert pb[f"period {i}"]["stress_period_data"] == [ + ("SAVE", "HEAD", "ALL"), + ("SAVE", "BUDGET", "LAST"), + ] def test_oc_period_steps_syntax(): @@ -2841,11 +2844,11 @@ def test_oc_period_steps_syntax(): ) pb = _period_blocks(oc) - assert ("SAVE", "BUDGET", "STEPS", 1, 3, 5) in pb["period 1"]["period"] - assert ("PRINT", "BUDGET", "STEPS", 1) in pb["period 1"]["period"] + assert ("SAVE", "BUDGET", "STEPS", 1, 3, 5) in pb["period 1"]["stress_period_data"] + assert ("PRINT", "BUDGET", "STEPS", 1) in pb["period 1"]["stress_period_data"] # no fill-forward: period 2 doesn't re-emit SAVE BUDGET - assert not any(t[:2] == ("SAVE", "BUDGET") for t in pb["period 2"]["period"]) - assert ("PRINT", "BUDGET", "LAST") in pb["period 2"]["period"] + assert not any(t[:2] == ("SAVE", "BUDGET") for t in pb["period 2"]["stress_period_data"]) + assert ("PRINT", "BUDGET", "LAST") in pb["period 2"]["stress_period_data"] def test_oc_period_stop_sentinel(): @@ -2866,11 +2869,11 @@ def test_oc_period_stop_sentinel(): assert len(pb) == 3 for i in range(1, 4): - assert ("SAVE", "HEAD", "ALL") in pb[f"period {i}"]["period"] + assert ("SAVE", "HEAD", "ALL") in pb[f"period {i}"]["stress_period_data"] - assert ("SAVE", "BUDGET", "STEPS", 1) in pb["period 1"]["period"] - assert not any(t[:2] == ("SAVE", "BUDGET") for t in pb["period 2"]["period"]) - assert not any(t[:2] == ("SAVE", "BUDGET") for t in pb["period 3"]["period"]) + assert ("SAVE", "BUDGET", "STEPS", 1) in pb["period 1"]["stress_period_data"] + assert not any(t[:2] == ("SAVE", "BUDGET") for t in pb["period 2"]["stress_period_data"]) + assert not any(t[:2] == ("SAVE", "BUDGET") for t in pb["period 3"]["stress_period_data"]) def test_oc_period_mixed_keys_no_silent_drop(): @@ -2887,9 +2890,9 @@ def test_oc_period_mixed_keys_no_silent_drop(): ) pb = _period_blocks(oc) - assert ("SAVE", "HEAD", "FIRST") in pb["period 1"]["period"] - assert ("SAVE", "HEAD", "LAST") in pb["period 2"]["period"] - assert ("SAVE", "HEAD", "ALL") in pb["period 3"]["period"] + assert ("SAVE", "HEAD", "FIRST") in pb["period 1"]["stress_period_data"] + assert ("SAVE", "HEAD", "LAST") in pb["period 2"]["stress_period_data"] + assert ("SAVE", "HEAD", "ALL") in pb["period 3"]["stress_period_data"] def test_oc_dumps_steps_in_output(): @@ -2933,10 +2936,10 @@ def test_oc_period_frequency(): ) pb = _period_blocks(oc) - assert ("SAVE", "HEAD", "FREQUENCY", 2) in pb["period 1"]["period"] - assert ("SAVE", "HEAD", "FREQUENCY", 2) in pb["period 2"]["period"] - assert ("SAVE", "HEAD", "FREQUENCY", 2) in pb["period 3"]["period"] - assert ("SAVE", "BUDGET", "ALL") in pb["period 1"]["period"] + assert ("SAVE", "HEAD", "FREQUENCY", 2) in pb["period 1"]["stress_period_data"] + assert ("SAVE", "HEAD", "FREQUENCY", 2) in pb["period 2"]["stress_period_data"] + assert ("SAVE", "HEAD", "FREQUENCY", 2) in pb["period 3"]["stress_period_data"] + assert ("SAVE", "BUDGET", "ALL") in pb["period 1"]["stress_period_data"] # --------------------------------------------------------------------------- @@ -2967,7 +2970,7 @@ def test_lak_period_lake_keywords(): ) pb = _lak_period_blocks(lak) - rows_p1 = pb["period 1"]["period"] + rows_p1 = pb["period 1"]["stress_period_data"] assert (1, "STATUS", "ACTIVE") in rows_p1 # emitted 1-based assert (2, "STATUS", "CONSTANT") in rows_p1 assert (2, "STAGE", 5.0) in rows_p1 @@ -2991,7 +2994,7 @@ def test_lak_period_outlet_keywords(): ) pb = _lak_period_blocks(lak) - rows = pb["period 1"]["period"] + rows = pb["period 1"]["stress_period_data"] assert (1, "RATE", 100.0) in rows # emitted 1-based assert (2, "RATE", 200.0) in rows assert (1, "INVERT", 4.5) in rows @@ -4018,7 +4021,7 @@ def test_lkt_period_keywords(): } ) pb = _lkt_period_blocks(lkt) - rows = pb["period 1"]["period"] + rows = pb["period 1"]["stress_period_data"] assert (1, "STATUS", "ACTIVE") in rows # emitted 1-based assert (2, "STATUS", "CONSTANT") in rows assert (1, "CONCENTRATION", 10.0) in rows @@ -4134,7 +4137,7 @@ def test_lke_period_keywords(): } ) pb = _lke_period_blocks(lke) - rows = pb["period 1"]["period"] + rows = pb["period 1"]["stress_period_data"] assert (1, "STATUS", "ACTIVE") in rows # emitted 1-based assert (2, "STATUS", "CONSTANT") in rows assert (1, "TEMPERATURE", 15.0) in rows @@ -5225,6 +5228,47 @@ def test_computed_dimension_does_not_warn(): structure_component(raw, Chd) +@pytest.mark.parametrize("row", ["MAXBOUND two", "MAXBOUND"]) +def test_computed_dimension_bad_value(row): + """MF6 stops on a bad MAXBOUND, so a value that's never used still has + to be one it would read.""" + from flopy4.mf6.converter.ingress.structure import structure_component + + raw = loads(f"BEGIN DIMENSIONS\n {row}\nEND DIMENSIONS\n") + with pytest.raises(ValueError, match=f"Chd: DIMENSIONS entry {row.upper()} needs an integer"): + structure_component(raw, Chd) + + +@pytest.mark.parametrize( + "text, match", + [ + ( + "BEGIN OPTIONS\n SAVE_FLOWS\nBEGIN DIMENSIONS\n MAXBOUND 2\nEND DIMENSIONS\n", + "OPTIONS block, opened on line 1, has no END: found BEGIN DIMENSIONS", + ), + ( + "\nBEGIN PERIOD 1\n 1 1 1 5.0\nBEGIN PERIOD 2\n 1 1 1 6.0\nEND PERIOD 2\n", + "PERIOD 1 block, opened on line 2, has no END: found BEGIN PERIOD 2", + ), + ( + "BEGIN OPTIONS\n SAVE_FLOWS\nEND DIMENSIONS\n", + "OPTIONS block, opened on line 1, has no END: found END DIMENSIONS", + ), + ], +) +def test_block_without_end(text, match): + """A block missing its END doesn't swallow the next one, as MF6 won't.""" + with pytest.raises(ValueError, match=match): + loads(text) + + +def test_block_end_without_index(): + """END needn't repeat a block's index, or its case.""" + assert loads("BEGIN period 1\n 1 2\nEND PERIOD\n") == loads( + "BEGIN period 1\n 1 2\nEND period 1\n" + ) + + def test_options_open_close(tmp_path): """An options block can be OPEN/CLOSE-redirected to a file.""" from flopy4.mf6.converter.ingress.structure import structure_component diff --git a/test/mf6/test_mf6_codegen.py b/test/mf6/test_mf6_codegen.py index c6234780..0d4d50ed 100644 --- a/test/mf6/test_mf6_codegen.py +++ b/test/mf6/test_mf6_codegen.py @@ -1241,7 +1241,7 @@ def test_tagged_file_list_is_repeatable_field(tmp_path, all_dfns, monkeypatch): assert "converter=attrs.converters.optional(to_list(Path))," in text -def test_tagged_record_list_roundtrip(tmp_path): +def test_tagged_record_list_roundtrip(tmp_path, monkeypatch): """A tagged list of (non-file) records is a repeatable list[RecordClass] field: generated, loaded one element per line, and written back one line per element. No real DFN has one yet, so a synthetic one.""" @@ -1290,7 +1290,7 @@ def test_tagged_record_list_roundtrip(tmp_path): assert [line for line in lines if line.startswith("SCALE")] == ["SCALE 2.0", "SCALE 3.0"] -def test_union_list_outside_period_roundtrip(tmp_path): +def test_union_list_outside_period_roundtrip(tmp_path, monkeypatch): """A list of unions gets the same arm classes and keyword dispatch in any block, not just the period block. No real DFN has one outside the period block yet, so a synthetic one.""" diff --git a/test/mf6/test_mf6_component.py b/test/mf6/test_mf6_component.py index 4b559fcf..3d90371c 100644 --- a/test/mf6/test_mf6_component.py +++ b/test/mf6/test_mf6_component.py @@ -779,7 +779,7 @@ def test_load_several_solution_groups(function_tmpdir): text += f"\nBEGIN SOLUTIONGROUP 2\n{second}\nEND SOLUTIONGROUP 2\n" nam.write_text(text) - with pytest.raises(ValueError, match="more than one solution group"): + with pytest.raises(ValueError, match="more than one solutiongroup block"): Simulation.load(nam) diff --git a/test/mf6/test_mf6_external_arrays.py b/test/mf6/test_mf6_external_arrays.py index 11bccdd4..aa428735 100644 --- a/test/mf6/test_mf6_external_arrays.py +++ b/test/mf6/test_mf6_external_arrays.py @@ -260,6 +260,84 @@ def test_shared_outside_file_copied_once(tmp_path): assert (out / "rch_1.txt").read_text().split() == ["0.2"] * 4 +@pytest.fixture +def scaled_rcha(tmp_path): + """RCHA periods 1 and 2 from one file, scaled by different FACTORs.""" + ws = tmp_path / "ws" + ws.mkdir() + (ws / "rch.txt").write_text("1.0 2.0 3.0 4.0\n") + (ws / "m.rcha").write_text( + textwrap.dedent("""\ + BEGIN OPTIONS + READASARRAYS + END OPTIONS + BEGIN PERIOD 1 + RECHARGE + OPEN/CLOSE rch.txt FACTOR 0.5 + END PERIOD 1 + BEGIN PERIOD 2 + RECHARGE + OPEN/CLOSE rch.txt FACTOR 2.0 IPRN 1 + END PERIOD 2 + """) + ) + rcha = Rcha.load(ws / "m.rcha", dims={"nlay": 1, "nodes": 4}, context=LoadContext(workspace=ws)) + out = tmp_path / "out" + out.mkdir() + rcha.filename = str(out / "out.rcha") + return rcha + + +def test_load_applies_factor(scaled_rcha): + """The values are scaled by the FACTOR, which isn't kept.""" + assert np.ravel(scaled_rcha.recharge[0]).tolist() == [0.5, 1.0, 1.5, 2.0] + assert np.ravel(scaled_rcha.recharge[1]).tolist() == [2.0, 4.0, 6.0, 8.0] + io = scaled_rcha.write_context.arrays[("recharge", 1)] + assert io == ArrayIO(iprn=1, path=Path("rch.txt"), format="open/close", layered=False) + assert io.hash == array_hash([2.0, 4.0, 6.0, 8.0]) + + +def test_factored_shared_file_inlined(scaled_rcha): + """Periods scaling one file by different factors hold different + values, so can't share it: they're written inline.""" + with pytest.warns(UserWarning, match="hold different values; writing them inline"): + scaled_rcha.write() + assert _lines(scaled_rcha.path, "OPEN/CLOSE") == [] + assert not (scaled_rcha.path.parent / "rch.txt").exists() + + +def test_factored_shared_file_apart(scaled_rcha): + """With an "open/close" `array_format`, they're each written to a file + of their own instead, and load back the same.""" + with pytest.warns(UserWarning, match="writing .*period 1 to out_rcha_recharge_p1.txt"): + scaled_rcha.write(context=WriteContext(array_format="open/close")) + assert _lines(scaled_rcha.path, "OPEN/CLOSE") == [ + "OPEN/CLOSE out_rcha_recharge_p1.txt", + "OPEN/CLOSE out_rcha_recharge_p2.txt IPRN 1", + ] + out = scaled_rcha.path.parent + assert not (out / "rch.txt").exists() + dims = {"nlay": 1, "nodes": 4} + again = Rcha.load(scaled_rcha.path, dims=dims, context=LoadContext(workspace=out)) + for kper in (0, 1): + assert np.array_equal(again.recharge[kper], scaled_rcha.recharge[kper]) + + +def test_edited_array_apart(shared_rcha): + """Of arrays sharing a file, one edited since loaded goes to a file of + its own with an "open/close" `array_format`; the others keep it.""" + shared_rcha.recharge[0][:] = 0.5 + with pytest.warns(UserWarning, match="period 1 changed since loaded"): + shared_rcha.write(context=WriteContext(array_format="open/close")) + assert _lines(shared_rcha.path, "OPEN/CLOSE") == [ + "OPEN/CLOSE out_rcha_recharge_p1.txt", + "OPEN/CLOSE rch.txt", + ] + out = shared_rcha.path.parent + assert (out / "out_rcha_recharge_p1.txt").read_text().split() == ["0.5"] * 4 + assert (out / "rch.txt").read_text().split() == ["0.1"] * 4 + + _HEADER = struct.Struct(" list[str]: + return [f.name for f in fields] + + +def test_blocks_in_file_order(): + assert list(spec.file_blocks(Chd)) == ["options", "dimensions", "period"] + # DIMENSIONS holds only the computed MAXBOUND + assert spec.file_blocks(Chd)["dimensions"] == [] + assert spec.block_keys(Chd, "dimensions").computed == ("maxbound",) + # MAXBOUND's beside a stored dimension + assert _names(spec.file_blocks(Evt)["dimensions"]) == ["nseg"] + assert spec.block_keys(Evt, "dimensions").computed == ("maxbound",) + assert spec.block_keys(Evt, "options").computed == () + + +def test_shared_keyword(): + head = spec.block_keys(Oc, "options").tagged["head"] + assert _names(head) == ["head_file", "headprint"] + assert [spec.following_tags(f) for f in head] == [["fileout"], ["print_format"]] + # no clash between a record and another field: TS's SFAC and SFACS + sfac = spec.block_keys(Ts, "attributes").tagged + assert _names(sfac["sfac"]) == ["sfacrecord_single"] + assert _names(sfac["sfacs"]) == ["sfac"] + + +def test_alias(): + tagged = spec.block_keys(Ts, "attributes").tagged + assert tagged["names"] == tagged["name"] + + +def test_untagged(): + assert spec.block_keys(Chd, "period").untagged.name == "_stress_period_data" + assert spec.block_keys(Sto, "period").untagged.name == "stress_period_data" + assert spec.block_keys(Tas, "time").untagged.name == "tas_array" + # rows that lead with a value, whatever keyword follows it + lak = spec.block_keys(Lak, "period") + assert lak.untagged.name == "_stress_period_data" + assert not lak.tagged + + +def test_tagged_lists(): + period = spec.block_keys(Oc, "period") + assert period.untagged is None + assert set(period.tagged) == {"save", "print"} + # a union's items and its plain words + period = spec.block_keys(Prp, "period") + assert {"first", "all", "last", "frequency", "steps"} <= set(period.tagged) + + +def test_dynamic_keys(): + period = spec.block_keys(Rcha, "period") + assert {path: f.name for path, f in period.dynamic.items()} == {"options.auxiliary": "aux"} + assert set(period.tagged) == {"irch", "recharge"} + assert period.untagged is None + + +def test_binding_rows_arent_keyed(): + group = spec.block_keys(Simulation, "solutiongroup") + assert group.untagged is None + assert set(group.tagged) == {"mxiter"} + assert "solutiongroup" in spec.binding_fields(Simulation) + + +@pytest.fixture(scope="module") +def generated(dfn_path, tmp_path_factory): + """Each component's DFN, with the class generated from it: by the DFNs + at hand, so this holds whichever the tests are given.""" + dfns = LocalDfnRegistry(path=dfn_path).spec(schema_version="2.0.0.dev3").components + specs = make_modules(dfns=dfns, outdir=tmp_path_factory.mktemp("routing"), makedirs=True) + registered = dict(FNAMES) + loaded = [] + out = [] + for s in specs: + path = Path(s.outpath) + if path.name == "__init__.py" or s.dfn_name not in dfns: + continue + name = f"_routing_{s.dfn_name.replace('-', '_')}" + module_spec = importlib.util.spec_from_file_location(name, path) + module = importlib.util.module_from_spec(module_spec) + sys.modules[name] = module + loaded.append(name) + module_spec.loader.exec_module(module) + out.append((dfns[s.dfn_name], getattr(module, s.class_name))) + yield out + FNAMES.clear() + FNAMES.update(registered) + for name in loaded: + del sys.modules[name] + + +def _following_dfn(f) -> list[str]: + """What follows a DFN field's leading keyword, for the rows the converter + has to tell apart.""" + if not isinstance(f, Record): + return [] + members = list(f.fields.values()) + if len(members) < 2: + return [] + second = members[1] + if isinstance(second, Keyword): + return [t.lower() for t in [second.name, *second.aliases]] + if isinstance(second, File) and second.mode_keyword and second.direction: + return [f"file{second.direction}"] + return [] + + +def test_classes_route_as_their_dfns(generated): + """What the converter reads from a class is what its DFN says: its blocks + in order, each block's keys in order, its untagged and dynamic fields, and + its repeating blocks' headers.""" + assert generated + problems = [] + for component, cls in generated: + blocks = spec.file_blocks(cls) + order = [b for b in component.blocks or {} if b in blocks] + if order != list(blocks): + problems.append((component.name, "order", list(blocks), order)) + for name in blocks: + where = (component.name, name) + block = component.blocks.get(name) + if block is None: + problems.append((*where, "not in the DFN")) + continue + keys = spec.block_keys(cls, name) + fields = [f for b, f in filters.flat_fields(component) if b == name] + binding = name in spec.binding_fields(cls) + + # a field's own keys (a union's arms) can come in any order + words = [ + t.lower() for f in fields if not _is_dynamic(f) for t in sorted(_leading_tags(f)) + ] + have = list(keys.computed) + for a in blocks[name]: + keyed = spec.is_tagged(a) and a not in keys.dynamic.values() + if keyed and not a.metadata.get("row"): + have += sorted(spec.leading_tags(a)) + words, have = list(dict.fromkeys(words)), list(dict.fromkeys(have)) + if words != have: + problems.append((*where, "keys", have, words)) + for word, shared in keys.tagged.items(): + if len(shared) > 1: + dfn_shared = [f for f in fields if word in map(str.lower, _leading_tags(f))] + want = [_following_dfn(f) for f in dfn_shared] + if [spec.following_tags(a) for a in shared] != want: + problems.append((*where, "following", word)) + + untagged = [f for f in fields if not getattr(f, "tagged", True)] + if binding: + untagged = [] + if (keys.untagged is None) != (not untagged): + problems.append((*where, "untagged", keys.untagged, _names(untagged))) + dynamic = { + next(iter(_record(f).fields.values())).fk.path for f in fields if _is_dynamic(f) + } + if set(keys.dynamic) != dynamic: + problems.append((*where, "dynamic", set(keys.dynamic), dynamic)) + + if block.header is None: + if name in cls.headers: + problems.append((*where, "header not in the DFN")) + continue + header = cls.headers[name] + kind = block.header.field.type + if header.kind != kind or header.index != bool(getattr(block.header.field, "index", 0)): + problems.append((*where, "header", header, kind)) + filled = any(a.metadata.get("fill_forward") for a in blocks[name]) + if filled != bool(block.header.fill_forward): + problems.append((*where, "fill_forward", filled)) + if spec.computed_fields(cls): + dims = component.blocks["dimensions"].fields + if next(iter(dims)) != "maxbound": + problems.append((component.name, "maxbound isn't first", list(dims))) + assert problems == [] + + +def _record(f): + return f.item if isinstance(f, ListField) else f + + +def _is_dynamic(f) -> bool: + record = _record(f) + if not isinstance(record, Record): + return False + return _is_dynamic_key(next(iter(record.fields.values()), None))