nsidc.metgen.readers.utilities

Functions

check_premet_keys(entry_type, parsed, expected)

closed_polygon(raw_points)

Return a copy of the input list, extended if necessary to ensure the first and last points of the list have the same value.

ensure_iso_datetime(datetime_str)

Parse ISO-standard datetime strings without a timezone identifier.

external_spatial_values(configuration, gsr, ...)

Retrieve spatial information from a granule-specific spatial or spo file, or the collection metadata.

external_temporal_values(...)

Extract temporal information from collection metadata or premet files according to .ini file settings.

find_key_aliases(aliases, datetime_parts)

format_timezone(iso_obj)

parse_additional_attributes(premet_file)

parse_platform_details(premet_file)

parse_premet_entry(pline)

Break up a "key = value" pair, removing any beginning/trailing whitespace from the string parts.

parse_spatial(spatial_values[, configuration])

parse_spo(gsr, points)

Reverse the order of the points to comply with the Cumulus requirement for a clockwise order to polygon points, and ensure the polygon is closed.

points_from_collection(collection_spatial)

Parse spatial information from collection metadata.

points_from_spatial(spatial_path, gsr[, ...])

Read (lon, lat) points from a .spatial or .spo file.

premet_values(premet_path)

Read premet file and return a dict containing temporal information and any included additional attributes and/or platform information.

raw_points(spatial_path)

refine_temporal(tvals)

Reformat a list of temporal values to match the format from UMM-C metadata

temporal_from_premet(pdict)

Extract temporal information from premet file contents.

valid_spatial_config(gsr, point_count)