From ca9600d54f87de48817d2b557ee7b852fc9c66eb Mon Sep 17 00:00:00 2001 From: garciam Date: Thu, 10 Oct 2024 10:35:19 +0200 Subject: [PATCH] added missing descriptions added missing descriptions --- cdsobs/cdm/api.py | 5 +- .../service_definition.yml | 34 ++-------- .../service_definition.yml | 65 +++++++++++++++++++ 3 files changed, 76 insertions(+), 28 deletions(-) diff --git a/cdsobs/cdm/api.py b/cdsobs/cdm/api.py index d624b3d..2a4e57c 100644 --- a/cdsobs/cdm/api.py +++ b/cdsobs/cdm/api.py @@ -99,13 +99,16 @@ def get_cdm_fields(cdm_tables: CDMTables) -> list[str]: ) cdm_variables += cdm_variables_with_table_names if "uncertainty_table" in cdm_tables: + n_uncertainties = 17 vars_supporting_numbers = [ "uncertainty_type", "uncertainty_units", "uncertainty_value", ] numbered_fields = [ - v + str(n) for v in vars_supporting_numbers for n in range(1, 17) + v + str(n) + for v in vars_supporting_numbers + for n in range(1, n_uncertainties + 1) ] cdm_variables += numbered_fields return cdm_variables diff --git a/cdsobs/data/insitu-observations-gruan-reference-network/service_definition.yml b/cdsobs/data/insitu-observations-gruan-reference-network/service_definition.yml index 472c3fa..751c9f9 100644 --- a/cdsobs/data/insitu-observations-gruan-reference-network/service_definition.yml +++ b/cdsobs/data/insitu-observations-gruan-reference-network/service_definition.yml @@ -105,35 +105,15 @@ sources: description: Barometric air pressure using silicon sensor up to 15.4 km, derived from GPS-altitude above dtype: float32 units: Pa - uncertainty_value1: - description: Uncertainty value 1 + uncertainty_valueN: + description: "Uncertainty value N. Available uncertainty types are: 1 (random), 2 (systematic) and 5 (total)" dtype: float32 - units: See uncertainty_units1 - uncertainty_type1: - description: Uncertainty type 1 + units: Defined in uncertainty_unitsN + uncertainty_typeN: + description: Uncertainty type N dtype: uint8 - uncertainty_units1: - description: Uncertainty units 1 - dtype: object - uncertainty_value2: - description: Uncertainty value 2 - dtype: float32 - units: See uncertainty_units2 - uncertainty_type2: - description: Uncertainty type 2 - dtype: uint8 - uncertainty_units2: - description: Uncertainty units 2 - dtype: object - uncertainty_value5: - description: Uncertainty value 5 - dtype: float32 - units: See uncertainty_units5 - uncertainty_type5: - description: Uncertainty type 5 - dtype: uint8 - uncertainty_units5: - description: Uncertainty units 5 + uncertainty_unitsN: + description: Units for uncertainty type N. dtype: object air_relative_humidity_effective_vertical_resolution: description: Resolution (defined by 1 / cut-off frequency) of the relative humidity time in terms diff --git a/cdsobs/data/insitu-observations-near-surface-temperature-us-climate-reference-network/service_definition.yml b/cdsobs/data/insitu-observations-near-surface-temperature-us-climate-reference-network/service_definition.yml index c53f329..d0f032b 100644 --- a/cdsobs/data/insitu-observations-near-surface-temperature-us-climate-reference-network/service_definition.yml +++ b/cdsobs/data/insitu-observations-near-surface-temperature-us-climate-reference-network/service_definition.yml @@ -225,6 +225,22 @@ sources: description: Average soil temperature measured at 5 cm below the surface level over the aggregation period. dtype: float32 units: K + uncertainty_valueN: + description: "Uncertainty value N. Available uncertainty types are: 8 (negative random), 9 (positive random), 10 (negative systematic), 11 (positive systematic), 12 (negative quasisystematic), 13 (positive quasisystematic), 16 (negative total) and 17 (positive total)." + dtype: float32 + units: Defined in uncertainty_unitsN + uncertainty_typeN: + description: Uncertainty type N + dtype: uint8 + uncertainty_unitsN: + description: Units for uncertainty type N. + dtype: object + quality_flag: + description: Quality flag for observation + dtype: uint8 + processing_level: + description: Level of processing applied to observation. + dtype: uint8 main_variables: - air_temperature - daily_maximum_air_temperature @@ -481,6 +497,22 @@ sources: description: The quantity with standard name downward_shortwave_irradiance_at_earth_surface, often called Total Solar Irradiance (TSI), is the radiation from the sun integrated over the whole electromagnetic spectrum and over the entire solar disk. The quantity applies outside the atmosphere, by default at a distance of one astronomical unit from the sun, but a coordinate or scalar coordinate variable of distance_from_sun can be used to specify a value other than the default. "Irradiance" means the power per unit area (called radiative flux in other standard names), the area being normal to the direction of flow of the radiant energy. dtype: float32 units: W m-2 + uncertainty_valueN: + description: "Uncertainty value N. Available uncertainty types are: 1 (random), 10 (negative systematic), 11 (positive systematic), 12 (negative quasisystematic), 13 (positive quasisystematic), 16 (negative total) and 17 (positive total)." + dtype: float32 + units: Defined in uncertainty_unitsN + uncertainty_typeN: + description: Uncertainty type N + dtype: uint8 + uncertainty_unitsN: + description: Units for uncertainty type N. + dtype: object + quality_flag: + description: Quality flag for observation + dtype: uint8 + processing_level: + description: Level of processing applied to observation. + dtype: uint8 main_variables: - air_temperature - daily_maximum_air_temperature @@ -658,6 +690,22 @@ sources: description: Average infrared temperature of the soil measured using infrared thermal imaging technology, over the aggregation period. dtype: float32 units: K + uncertainty_valueN: + description: "Uncertainty value N. Available uncertainty types are: 1 (random), 10 (negative systematic), 11 (positive systematic), 12 (negative quasisystematic), 13 (positive quasisystematic) , 16 (negative total) and 17 (positive total)." + dtype: float32 + units: Defined in uncertainty_unitsN + uncertainty_typeN: + description: Uncertainty type N + dtype: uint8 + uncertainty_unitsN: + description: Units for uncertainty type N. + dtype: object + quality_flag: + description: Quality flag for observation + dtype: uint8 + processing_level: + description: Level of processing applied to observation. + dtype: uint8 main_variables: - air_temperature - daily_maximum_air_temperature @@ -814,6 +862,23 @@ sources: description: This parameter is the horizontal velocity of the air near the surface. It is measured using a 3-cup anemometer placed at the same height at the air temperature shield intake. The exact measurement height is 1.5 metres above the ground surface. dtype: float32 units: m s-1 + uncertainty_valueN: + description: "Uncertainty value N. Available uncertainty types are: 1 (random), 3 (quasisystematic), 10 (negative systematic), 11 (positive systematic), 16 (negative total) and 17 (positive total)." + dtype: float32 + units: Defined in uncertainty_unitsN + uncertainty_typeN: + description: Uncertainty type N + dtype: uint8 + uncertainty_unitsN: + description: Units for uncertainty type N. + dtype: object + quality_flag: + description: Quality flag for observation + dtype: uint8 + processing_level: + description: Level of processing applied to observation. + dtype: uint8 + main_variables: - air_temperature - accumulated_precipitation