xugrid.Ugrid2d.topology_subset#
- Ugrid2d.topology_subset(face_index: ndarray, return_index: bool = False)[source]#
Create a new UGRID1D topology for a subset of this topology.
- Parameters:
face_index (1d array of integers or bool) – Edges of the subset.
return_index (bool, optional) – Whether to return node_index, edge_index, face_index.
- Returns:
subset (Ugrid2d)
indexes (dict) – Dictionary with keys node dimension, edge dimension, face dimension and values their respective index. Only returned if return_index is True.