imod.prepare.cleanup_wel#

imod.prepare.cleanup_wel(wells: DataFrame, top: DataArray | UgridDataArray, bottom: DataArray | UgridDataArray, minimum_thickness: float = 0.05) DataFrame[source]#

Clean up dataframe with wells, fixes some common mistakes in the following order:

  1. Wells outside grid bounds are dropped

  2. Filters above surface level are set to surface level

  3. Drop wells with filters entirely below base

  4. Clip filter screen_bottom to model base

  5. Clip filter screen_bottom to screen_top

  6. Well filters thinner than minimum thickness are made point filters

Parameters:
  • wells (pandas.Dataframe) – Dataframe with wells to be cleaned up. Requires columns "x", "y", "id", "screen_top", "screen_bottom"

  • top (xarray.DataArray | xugrid.UgridDataArray) – Grid with model top

  • bottom (xarray.DataArray | xugrid.UgridDataArray) – Grid with model bottoms

  • minimum_thickness (float) – Minimum thickness, filter thinner than this thickness are set to point filters

Returns:

Cleaned well dataframe.

Return type:

pandas.DataFrame