libera_utils.io.umm_g.UMMGDatasetTransformer#
- class libera_utils.io.umm_g.UMMGDatasetTransformer(input_dataset: Dataset, log_warnings: bool = False)#
Bases:
objectCLass containing methods to go from an input dataset to UMMGranule objects.
Methods
Extract access constraints from dataset attributes.
Extract additional attributes from dataset attributes.
Extract cloud cover percentage from dataset attributes.
Extract collection reference from dataset attributes.
extract_data_granule([filepath])Extract data granule information from dataset attributes.
Extract GranuleUR from dataset attributes.
Extract grid mapping names from dataset attributes.
Extract input granules from dataset attributes.
Extract measured parameters from dataset variables.
Extract native projection names from dataset attributes.
Extract orbit calculated spatial domains from dataset attributes.
Extract PGE version information from dataset attributes.
Extract platform information from dataset attributes.
Extract project information from dataset attributes.
Extract provider dates from dataset attributes.
Extract related URLs from dataset attributes.
Extract spatial extent from dataset attributes.
Extract temporal extent from dataset attributes.
Extract tiling identification system from dataset attributes.
- __init__(input_dataset: Dataset, log_warnings: bool = False)#
Create the transformer object from input_dataset.
The UMM granule is stored in the attribute umm_granule.
- Parameters:
input_dataset (xr.Dataset) – The input dataset read from a netCDF file to convert into a UMMGranule object.
log_warnings (bool) – Indicates whether warnings while extracting values from the dataset should be logged out, or only stored in the “warnings” attribute. Note that this does not affect validation warnings or errors, only warnings from the transformation step within the class.
Methods
Extract access constraints from dataset attributes.
Extract additional attributes from dataset attributes.
Extract cloud cover percentage from dataset attributes.
Extract collection reference from dataset attributes.
extract_data_granule([filepath])Extract data granule information from dataset attributes.
Extract GranuleUR from dataset attributes.
Extract grid mapping names from dataset attributes.
Extract input granules from dataset attributes.
Extract measured parameters from dataset variables.
Extract native projection names from dataset attributes.
Extract orbit calculated spatial domains from dataset attributes.
Extract PGE version information from dataset attributes.
Extract platform information from dataset attributes.
Extract project information from dataset attributes.
Extract provider dates from dataset attributes.
Extract related URLs from dataset attributes.
Extract spatial extent from dataset attributes.
Extract temporal extent from dataset attributes.
Extract tiling identification system from dataset attributes.
- _to_umm_granule(filepath: str | None = None) UMMGranule#
Build complete UMM-G granule from dataset.
- extract_access_constraints() AccessConstraintsType | None#
Extract access constraints from dataset attributes.
- extract_additional_attributes() list[AdditionalAttributeType] | None#
Extract additional attributes from dataset attributes.
- extract_collection_reference() CollectionReferenceType#
Extract collection reference from dataset attributes.
- extract_data_granule(filepath: str | None = None) DataGranuleType | None#
Extract data granule information from dataset attributes.
- extract_measured_parameters() list[MeasuredParameterType] | None#
Extract measured parameters from dataset variables.
- extract_native_projection_names() list[ProjectionNameEnum] | None#
Extract native projection names from dataset attributes.
- extract_orbit_calculated_spatial_domains() list[OrbitCalculatedSpatialDomainType] | None#
Extract orbit calculated spatial domains from dataset attributes.
- extract_pge_version_class() PGEVersionClassType | None#
Extract PGE version information from dataset attributes.
- extract_platforms() list[PlatformType] | None#
Extract platform information from dataset attributes.
- extract_projects() list[ProjectType] | None#
Extract project information from dataset attributes.
- extract_provider_dates() list[ProviderDateType]#
Extract provider dates from dataset attributes.
Extract related URLs from dataset attributes.
- extract_spatial_extent() SpatialExtentType | None#
Extract spatial extent from dataset attributes.
- extract_temporal_extent() TemporalExtentType | None#
Extract temporal extent from dataset attributes.
- extract_tiling_identification_system() TilingIdentificationSystemType | None#
Extract tiling identification system from dataset attributes.