hydromodpy.solver.boussinesq.runtimes.picard.diagnostics#

Shared math/geometry helpers and record types for the Picard/L-scheme runtimes.

Functions

active_state(*, head, lower, upper, ...)

Return the active-state label for one cell.

cell_coord(mesh, index, names)

Return the first finite coordinate value found for the given attribute names.

cell_id(mesh, index)

Return the cell_id at one mesh index.

clip_head(head_m, *, lower, upper, ...)

Clip a head vector inside the (lower, upper) bounds when requested.

free_mask_from_bounds(*, head, lower, upper, ...)

Return the boolean mask of cells strictly inside the bounds.

free_residual_norm(*, residual, head, lower, ...)

Return the free-cell raw balance norm, excluding active obstacles.

jsonable(value)

Recursively convert dataclasses/np arrays/scalars to JSON-safe Python values.

neighbor_counts(mesh)

Return the number of internal-edge neighbors per cell.

obstacle_tolerance(inputs)

Return the tolerance used to classify active obstacle cells.

physical_bounds(mesh, prescribed_head_m_by_cell)

Return physical head bounds and the prescribed mask.

prescribed_head_cells(...)

Coerce prescribed heads to a (n_cells,) NaN-padded vector.

quantiles(values)

Return a quantile summary dict for an array (NaN-safe).

Classes

PicardIterationRecord(iteration, omega, ...)

One persisted Picard iteration diagnostic row.

PicardLschemeOptions(*[, ...])

Options for the experimental strict bounded Picard/L-scheme solve.

PicardViCycleOptions(*[, cycle_max, ...])

Options for strict Picard/VI cycling.

PicardViCycleRecord(cycle, ...[, note])

One persisted Picard/VI cycle diagnostic row.