update_metadata
- s100py.s104.v2_0.utils.update_metadata(data_file, grid_properties, metadata)
Updates an S104File object based on dynamic metadata.
- Parameters:
data_file – S104File object
grid_properties (
dict) –a dictionary of metadata describing the dynamic data passed in, metadata can have the following key/value pairs:
”minx”: West bound longitude
”maxx”: East bound longitude
”miny”: South bound latitude
”maxy”: North bound latitude
”cellsize_x”: Only for DCF2, grid spacing longitude
”cellsize_y”: Only for DCF2, grid spacing latitude
”nx”: Only for DCF2, number of points longitudinal
”ny”: Only for DCF2, number of points latitudinal
metadata (
dict) –a dictionary of metadata describing the data, metadata must have the following key/value pairs:
”dateTimeOfFirstRecord”: Valid time of earliest value, ‘YYYYMMDDTHHMMSSZ’
”dataDynamicity”: Classification of data according to the relationship between the time of its
collection, generation, or calculation of generation parameters, in relation to the time of publication of the dataset
’observation’: 1
’astronomicalPrediction’: 2
’analysisOrHybrid’: 3
’hydrodynamicForecast’: 5
- Returns:
An S104File object updated by this function.
- Return type:
data_file