ndpyramid.pyramid_regrid#
- ndpyramid.pyramid_regrid(ds: Dataset, projection: Literal['web-mercator', 'equidistant-cylindrical'] = 'web-mercator', target_pyramid: DataTree | None = None, levels: int | None = None, weights_pyramid: DataTree | None = None, method: str = 'bilinear', regridder_kws: dict | None = None, regridder_apply_kws: dict | None = None, other_chunks: dict | None = None, pixels_per_tile: int = 128) DataTree #
Make a pyramid using xesmf’s regridders
Parameters#
- dsxr.Dataset
Input dataset
- projectionstr, optional
Projection to use for the grid, by default ‘web-mercator’
- target_pyramiddt.DataTree, optional
Target grids, if not provided, they will be generated, by default None
- levelsint, optional
Number of levels in pyramid, by default None
- weights_pyramiddt.DataTree, optional
pyramid containing pregenerated weights
- methodstr, optional
Regridding method. See
Regridder
for valid options, by default ‘bilinear’- regridder_kwsdict
Keyword arguments to pass to regridder. Default is {‘periodic’: True}
- regridder_apply_kwsdict
Keyword arguments such as keep_attrs, skipna, na_thres to pass to
__call__()
. Default is None- other_chunksdict
Chunks for non-spatial dims to pass to
chunk()
. Default is None- pixels_per_tileint, optional
Number of pixels per tile, by default 128
Returns#
- pyramiddt.DataTree
Multiscale data pyramid