resqpy.grid_surface.find_faces_to_represent_surface

resqpy.grid_surface.find_faces_to_represent_surface(grid, surface, name, mode='auto', feature_type='fault', progress_fn=None)

Returns a grid connection set containing those cell faces which are deemed to represent the surface.

Parameters
  • grid (RegularGrid) – the grid for which to create a grid connection set representation of the surface

  • surface (Surface) – the triangulated surface for which grid cell faces are required

  • name (str) – the feature name to use in the grid connection set

  • mode (str, default 'auto') – one of ‘auto’, ‘staffa’, ‘regular’, ‘regular_optimised’, ‘regular_cuda’; auto will translate to regular_optimised for regulat grids, and staffa for irregular grids; regular_cude required GPU hardware and the correct installation of numba.cuda and cupy

  • feature_type (str, default 'fault') – ‘fault’, ‘horizon’ or ‘geobody boundary’

  • (f(x (progress_fn) – float), optional): a callback function to be called at intervals by this function; the argument will progress from 0.0 to 1.0 in unspecified and uneven increments

Returns

a new GridConnectionSet with a single feature, not yet written to hdf5 nor xml created

Note

this is a wrapper function selecting between more specialised functions; use those directly for more options