myoverse.datasets.filters.spatial.SpatialFilterGridAware._filter#
- abstractmethod SpatialFilterGridAware._filter(input_array, **kwargs)[source]#
Apply the filter to the input array.
- Parameters:
input_array (np.ndarray) – The input array to filter.
**kwargs –
Additional keyword arguments from the Data object.
Important
”grid_layouts” must be passed in kwargs for this filter to work.
- Returns:
The filtered array.
- Return type:
np.ndarray
- Raises:
AttributeError – If the grid_layouts are not provided in kwargs. This filter only operates in grid-aware mode.
Notes
Important
Insure that the grid_layouts are updated using the new grid_layout. Use pass by reference stuff.
1for i, new_grid_layout in enumerate(new_grid_layouts): 2 grid_layouts[i] = new_grid_layout