iwfm.diagnostics.read_residual_hdf

iwfm.diagnostics.read_residual_hdf(hdf_path, n_gw_nodes, n_layers, max_iter_store=50, last_n_timesteps=12, top_n_nodes=20, verbose=False)[source]

Read Diagnostics_Residual.hdf using chunked access.

Only loads the last N timestep blocks to avoid reading the full 2+ GB file into memory.

Parameters:
  • hdf_path (str) – Path to Diagnostics_Residual.hdf.

  • n_gw_nodes (int) – Number of groundwater nodes per layer.

  • n_layers (int) – Number of model layers.

  • max_iter_store (int) – Max iterations stored per timestep (rows per timestep block).

  • last_n_timesteps (int) – Number of recent timesteps to process.

  • top_n_nodes (int) – Max number of worst nodes to report.

  • verbose (bool) – Print progress.

Return type:

ResidualSummary