uxarray.Grid.isel

Contents

uxarray.Grid.isel#

Grid.isel(**dim_kwargs)#

Indexes an unstructured grid along a given dimension (n_node, n_edge, or n_face) and returns a new grid.

Currently only supports inclusive selection, meaning that for cases where node or edge indices are provided, any face that contains that element is included in the resulting subset. This means that additional elements beyond those that were initially provided in the indices will be included. Support for more methods, such as exclusive and clipped indexing is in the works.

Parameters **dims_kwargs: kwargs

Dimension to index, one of [‘n_node’, ‘n_edge’, ‘n_face’]

Example

>> grid = ux.open_grid(grid_path) >> grid.isel(n_face = [1,2,3,4])