odc.geo.xr.ODCExtensionDs

class odc.geo.xr.ODCExtensionDs(ds)[source]

ODC extension for xarray.Dataset.

__init__(ds)[source]

Methods

__init__(ds)

assign_crs(crs[, crs_coord_name])

crop(poly[, apply_mask, all_touched])

Crops and optionally mask an xarray.Dataset or xarray.DataArray to the spatial extent of a geometry.

explore([map, bands, vmin, vmax, cmap, ...])

Plot xarray data on an interactive folium leaflet map for rapid data exploration.

map_bounds()

See odc.geo.geobox.GeoBox.map_bounds().

mask(poly[, invert, all_touched])

Apply a polygon geometry as a mask, setting all xarray.Dataset or xarray.DataArray pixels outside the rasterized polygon to NaN.

mask_clouds(qa_name, scale, offset, clip[, ...])

General cloud masking function for both Landsat and Sentinel-2 products.

mask_invalid_data([nodata, skip_bands])

Mask out invalid data values.

mask_ls([qa_name, include_cirrus, ...])

Perform cloud masking for Landsat Collection 2 products.

mask_s2([qa_name, include_cirrus, ...])

Perform cloud masking for Sentinel-2 L2A products.

output_geobox(crs, **kw)

Compute geobox of this data in other projection.

reload()

Reload geospatial state info in-place.

reproject(how, *[, resampling, dst_nodata, ...])

Reproject raster to different projection/resolution.

scale_and_offset([scale, offset, clip])

Apply scale and offset to the DataArray.

to_rgba([bands, vmin, vmax])

Convert dataset to RGBA image.

Attributes

affine

aspect

crs

Query CRS.

crs_coord

Return CRS coordinate DataArray.

geobox

Query GeoBox or GCPGeoBox.

grid_mapping

Return name of the grid mapping coordinate.

spatial_dims

Return names of spatial dimensions, or None.

transform

uncached