faninsar.datasets.GeoDataset#
- class faninsar.datasets.GeoDataset[source]#
Bases:
ABCAbstract base class for all
faninsardatasets.This class is used to represent a geospatial dataset and provides methods to index the dataset and retrieve information about the dataset, such as CRS, resolution, data type, no data value, and a bounds.
Methods
__init__()Initialize a new GeoDataset instance.
Attributes
Bounds of the overall dataset.
Coordinate reference system (CRS) of the dataset.
Data type of the dataset.
No data value of the dataset.
Return the resolution of the dataset.
Return the region of interest of the dataset.
Whether all files in the dataset have the same CRS with the desired CRS.
Shape of the dataset.
Return a boolean array indicating which files are valid.
- property bounds: BoundingBox#
Bounds of the overall dataset.
It is the union of all the files in the dataset.
- Returns:
bounds – (minx, right, bottom, top) of the dataset
- Return type:
BoundingBox object
- property crs: CRS | None#
Coordinate reference system (CRS) of the dataset.
- Return type:
The coordinate reference system (CRS).
- property dtype: dtype | None#
Data type of the dataset.
- Returns:
dtype – data type of the dataset
- Return type:
numpy.dtype object or None
- property res: tuple[float, float]#
Return the resolution of the dataset.
- Returns:
res – resolution of the dataset in x and y directions.
- Return type:
tuple of floats
- property roi: BoundingBox | None#
Return the region of interest of the dataset.
- Returns:
roi – region of interest of the dataset. If None, the bounds of entire dataset will be used.
- Return type:
BoundingBox object
- property shape: tuple[int, int]#
Shape of the dataset.
- Returns:
shape – shape of the dataset in (height, width) format
- Return type:
tuple of ints