pofff.utils.mapproperties module
Utility functions for grid generation and spatial indexing in geological FluidFlower-style models.
- pofff.utils.mapproperties.classify_boxes(cfg: PofffConfig, x: ndarray[tuple[Any, ...], dtype[float64]], z: ndarray[tuple[Any, ...], dtype[float64]], flux: list[str]) list[str]
Assign box-specific FIP numbers based on spatial regions.
- pofff.utils.mapproperties.corner(cfg: PofffConfig, points: list[list[float]]) tuple[ndarray[tuple[Any, ...], dtype[float64]], ndarray[tuple[Any, ...], dtype[float64]], ndarray[tuple[Any, ...], dtype[float64]]]
Build corner-point grid coordinates and compute cell centroids.
- pofff.utils.mapproperties.corner_point_handling_fluidflower(cfg: PofffConfig, xyz: ndarray[tuple[Any, ...], dtype[float64]], polygons: list[Polygon], xcoord: ndarray[tuple[Any, ...], dtype[float64]], zcoord: ndarray[tuple[Any, ...], dtype[float64]]) None
Assign facies, boxes, sensors, and wells for corner-point grids.
- pofff.utils.mapproperties.get_cellmaps(cfg: PofffConfig, simxcent: ndarray[tuple[Any, ...], dtype[float64]], simzcent: ndarray[tuple[Any, ...], dtype[float64]]) None
Construct mapping from structured grid to reference grid.
- pofff.utils.mapproperties.get_lines(cfg: PofffConfig, points: list[list[float]]) list[list[list[float]]]
Read geological horizon lines.
- pofff.utils.mapproperties.getpolygons(cfg: PofffConfig) tuple[list[Polygon], list[list[float]]]
Read geological polygons and facies definitions.
- pofff.utils.mapproperties.grid_and_properties(cfg: PofffConfig) None
Dispatch grid generation and spatial property assignment based on the selected grid type.
- pofff.utils.mapproperties.handle_thickness_map(cfg: PofffConfig) tuple[float, ndarray[tuple[Any, ...], dtype[_ScalarT]], ndarray[tuple[Any, ...], dtype[_ScalarT]], ndarray[tuple[Any, ...], dtype[_ScalarT]]]
Load and normalize thickness map and corresponding multipliers.
- pofff.utils.mapproperties.positions(cfg: PofffConfig, polygons: list[Polygon], xcent: ndarray[tuple[Any, ...], dtype[float64]] | None = None, zcent: ndarray[tuple[Any, ...], dtype[float64]] | None = None, xyz: ndarray[tuple[Any, ...], dtype[float64]] | None = None, xcoord: ndarray[tuple[Any, ...], dtype[float64]] | None = None, zcoord: ndarray[tuple[Any, ...], dtype[float64]] | None = None) None
Dispatch spatial indexing for either grid type.
- pofff.utils.mapproperties.refinement_z(xci: ndarray[tuple[Any, ...], dtype[float64]], zci: ndarray[tuple[Any, ...], dtype[float64]], ncz: int, znr: ndarray[tuple[Any, ...], dtype[float64]]) tuple[ndarray[tuple[Any, ...], dtype[float64]], ndarray[tuple[Any, ...], dtype[float64]], int, int]
Refine grid vertically according to znr refinement factors.
- pofff.utils.mapproperties.sensors_corner_point(cfg: PofffConfig, x: ndarray[tuple[Any, ...], dtype[float64]], ztop: ndarray[tuple[Any, ...], dtype[float64]]) tuple[int, int]
Determine corner-point sensor indices.
- pofff.utils.mapproperties.sensors_structured(cfg: PofffConfig, xcent: ndarray[tuple[Any, ...], dtype[float64]], zcent: ndarray[tuple[Any, ...], dtype[float64]]) tuple[int, int]
Determine structured-grid sensor indices.
- pofff.utils.mapproperties.structured_handling_fluidflower(cfg: PofffConfig, xcent: ndarray[tuple[Any, ...], dtype[float64]], zcent: ndarray[tuple[Any, ...], dtype[float64]], polygons: list[Polygon]) None
Assign facies, boxes, sensors, and wells on structured grids.
- pofff.utils.mapproperties.wells_corner_point(cfg: PofffConfig, x: ndarray[tuple[Any, ...], dtype[float64]], ztop: ndarray[tuple[Any, ...], dtype[float64]]) None
Determine corner-point well indices.
- pofff.utils.mapproperties.wells_structured(cfg: PofffConfig, xcent: ndarray[tuple[Any, ...], dtype[float64]], zcent: ndarray[tuple[Any, ...], dtype[float64]]) None
Determine structured-grid well indices.