warp.fem.ExplicitGeometryPartition#
- class warp.fem.ExplicitGeometryPartition(
- geometry,
- cell_mask,
- max_cell_count=-1,
- max_side_count=-1,
- temporary_store=None,
- Parameters:
geometry (Geometry)
cell_mask (wp.array(dtype=int))
max_cell_count (int)
max_side_count (int)
temporary_store (TemporaryStore | None)
- __init__(
- geometry,
- cell_mask,
- max_cell_count=-1,
- max_side_count=-1,
- temporary_store=None,
Creates a geometry partition from an active cell mask
- Parameters:
geometry (Geometry) – the geometry to partition
cell_mask (array(ndim=1, dtype=int32)) – warp array of length
geometry.cell_count()indicating which cells are selected. Array values must be either1(selected) or0(not selected).max_cell_count (int) – if positive, will be used to limit the number of cells to avoid device/host synchronization
max_side_count (int) – if positive, will be used to limit the number of sides to avoid device/host synchronization
temporary_store (TemporaryStore | None)
Methods
__init__(geometry, cell_mask[, ...])Creates a geometry partition from an active cell mask
boundary_side_count()cell_arg_value(device)compute_side_indices_from_cells(...[, ...])fill_cell_arg(args, device)fill_side_arg(args, device)frontier_side_count()rebuild(cell_mask[, temporary_store])Rebuilds the geometry partition from a new active cell mask
side_arg_value(device)side_count()Attributes
SideArgboundary_side_indexfrontier_side_indexnameside_indexside_to_cell_arggeometryUnderlying geometry
- rebuild(cell_mask, temporary_store=None)[source]#
Rebuilds the geometry partition from a new active cell mask
- Parameters:
geometry – the geometry to partition
cell_mask (array(ndim=1, dtype=int32)) – warp array of length
geometry.cell_count()indicating which cells are selected. Array values must be either1(selected) or0(not selected).max_cell_count – if positive, will be used to limit the number of cells to avoid device/host synchronization
max_side_count – if positive, will be used to limit the number of sides to avoid device/host synchronization
temporary_store (TemporaryStore | None)
- CellArg = <warp._src.codegen.Struct object>#