Scene#

class Scene[source]#

Bases: object

The raster data and labels associated with an area of interest.

Attributes

bbox

Bounding box applied to the source data.

extent

Extent of the associated RasterSource.

__init__(id: str, raster_source: RasterSource, label_source: Optional[LabelSource] = None, label_store: Optional[LabelStore] = None, aoi_polygons: Optional[List[BaseGeometry]] = None)[source]#

Constructor.

During initialization, Scene attempts to set the extents of the given label_source and the label_store to be identical to the extent of the given raster_source.

Parameters
  • id (str) – ID for this scene.

  • raster_source (RasterSource) – Source of imagery for this scene.

  • label_source (Optional[LabelSource]) – Source of labels for this scene.

  • label_store (Optional[LabelStore]) – Store of predictions for this scene.

  • aoi – Optional list of AOI polygons in pixel coordinates.

  • aoi_polygons (Optional[List[BaseGeometry]]) –

Methods

__init__(id, raster_source[, label_source, ...])

Constructor.

__getitem__(key: Any) Tuple[Any, Any][source]#
Parameters

key (Any) –

Return type

Tuple[Any, Any]

__init__(id: str, raster_source: RasterSource, label_source: Optional[LabelSource] = None, label_store: Optional[LabelStore] = None, aoi_polygons: Optional[List[BaseGeometry]] = None)[source]#

Constructor.

During initialization, Scene attempts to set the extents of the given label_source and the label_store to be identical to the extent of the given raster_source.

Parameters
  • id (str) – ID for this scene.

  • raster_source (RasterSource) – Source of imagery for this scene.

  • label_source (Optional[LabelSource]) – Source of labels for this scene.

  • label_store (Optional[LabelStore]) – Store of predictions for this scene.

  • aoi – Optional list of AOI polygons in pixel coordinates.

  • aoi_polygons (Optional[List[BaseGeometry]]) –

property bbox: Box#

Bounding box applied to the source data.

property extent: Box#

Extent of the associated RasterSource.