ndpyramid.pyramid_reproject#
- ndpyramid.pyramid_reproject(ds: Dataset, *, projection: Literal['web-mercator', 'equidistant-cylindrical'] = 'web-mercator', levels: int | None = None, pixels_per_tile: int = 128, other_chunks: dict | None = None, resampling: str | dict = 'average', extra_dim: str | None = None, clear_attrs: bool = False) DataTree #
Create a multiscale pyramid of a dataset via reprojection.
Parameters#
- dsxarray.Dataset
The dataset to create a multiscale pyramid of.
- projectionstr, optional
The projection to use. Default is ‘web-mercator’.
- levelsint, optional
The number of levels to create. If None, the number of levels is determined by the number of tiles in the dataset.
- pixels_per_tileint, optional
Number of pixels per tile, by default 128
- other_chunksdict
Chunks for non-spatial dims to pass to
chunk()
. Default is None- resamplingstr or dict, optional
Rasterio warp resampling method to use. Default is ‘average’. If a dict, keys are variable names and values are warp resampling methods.
- extra_dimstr, optional
The name of the extra dimension to iterate over. Default is None.
- clear_attrsbool, False
Clear the attributes of the DataArrays within the multiscale pyramid. Default is False.
Returns#
- dt.DataTree
The multiscale pyramid.