Skip to content

Documentation for Granule Results

Bases: CustomDict

Dictionary-like object to represent a granule from CMR.

__geo_interface__ property

A GeoJSON representation of this granule.

This granule must contain a dict value at the path self["umm"]["SpatialExtent"]["HorizontalSpatialDomain"]["Geometry"]. It is assumed that the dict contains only a single key-value pair, and this property is the result of converting the value of that pair into an equivalent GeoJSON structure, depending on the key, as follows:

Key Value converted to GeoJSON
"Lines" "MultiLineString"
"Points" "MultiPoint"
"BoundingRectangles" "MultiPolygon"
"GPolygons" "MultiPolygon"

Raises:

Type Description
ValueError

If this granule does not contain a value at the path self["umm"]["SpatialExtent"]["HorizontalSpatialDomain"]["Geometry"], or the value there is not a dict containing a value for one of "Points", "Lines", "BoundingRectangles", or "GPolygons".

See Also

__repr__()

Placeholder.

Returns:

Type Description
str

A basic representation of a data granule.

Placeholder.

Returns the data links from a granule.

Parameters:

Name Type Description Default
access Optional[str]

direct or external. Direct means in-region access for cloud-hosted collections.

None
in_region bool

True if we are running in us-west-2. It is meant for the store class.

False

Returns:

Type Description
List[str]

The data links for the requested access type.

Placeholder.

Returns:

Type Description
List[str]

The data visualization links, usually the browse images.

size()

Placeholder.

Returns:

Type Description
float

The total size for the granule in MB.