Skip to content

Commit

Permalink
Add rain-gauges
Browse files Browse the repository at this point in the history
  • Loading branch information
tukiains committed Jan 14, 2025
1 parent 9b507e2 commit 011d31f
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
1 change: 1 addition & 0 deletions cloudnetpy_qc/quality.py
Original file line number Diff line number Diff line change
Expand Up @@ -275,6 +275,7 @@ class TestDataCoverage(Test):
Product.MWR_MULTI: datetime.timedelta(minutes=30),
Product.MWR_SINGLE: datetime.timedelta(minutes=5),
Product.WEATHER_STATION: datetime.timedelta(minutes=10),
Product.RAIN_GAUGE: datetime.timedelta(minutes=1),
Product.DOPPLER_LIDAR_WIND: datetime.timedelta(hours=1.5),
}
DEFAULT_RESOLUTION = datetime.timedelta(seconds=30)
Expand Down
14 changes: 13 additions & 1 deletion cloudnetpy_qc/variables.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ class Product(Enum):
DOPPLER_LIDAR = "doppler-lidar"
DOPPLER_LIDAR_WIND = "doppler-lidar-wind"
RAIN_RADAR = "rain-radar"
RAIN_GAUGE = "rain-gauge"
# Level 1c
CATEGORIZE = "categorize"
MWR_L1C = "mwr-l1c"
Expand Down Expand Up @@ -55,6 +56,7 @@ def all(cls) -> set[Product]:
Product.MODEL: "1b",
Product.WEATHER_STATION: "1b",
Product.DOPPLER_LIDAR: "1b",
Product.RAIN_GAUGE: "1b",
Product.DOPPLER_LIDAR_WIND: "1c",
Product.RAIN_RADAR: "1b",
Product.CATEGORIZE: "1c",
Expand Down Expand Up @@ -170,7 +172,7 @@ def time_units(nc: netCDF4.Dataset) -> str:
long_name="Rainfall amount",
units="m",
standard_name="thickness_of_rainfall_amount",
required=[Product.WEATHER_STATION],
required=[Product.WEATHER_STATION, Product.RAIN_GAUGE],
),
# ------------------------------------
# Required in RAIN RADAR Level 1b file
Expand Down Expand Up @@ -784,6 +786,7 @@ def time_units(nc: netCDF4.Dataset) -> str:
units="m s-1",
standard_name="rainfall_rate",
required=[
Product.RAIN_GAUGE,
Product.DISDROMETER,
Product.WEATHER_STATION,
Product.RAIN_RADAR,
Expand Down Expand Up @@ -851,6 +854,7 @@ def time_units(nc: netCDF4.Dataset) -> str:
Product.MWR,
Product.DISDROMETER,
Product.WEATHER_STATION,
Product.RAIN_GAUGE,
Product.MWR_L1C,
Product.L3_CF,
Product.L3_IWC,
Expand Down Expand Up @@ -893,6 +897,14 @@ def time_units(nc: netCDF4.Dataset) -> str:
long_name="Radar range offset",
units="m",
),
"r_accum_RT": Variable(
long_name="Real time accumulated rainfall",
units="m",
),
"r_accum_NRT": Variable(
long_name="Near real time accumulated rainfall",
units="m",
),
"rainfall_rate_1min_total": Variable(
long_name="Total precipitation rate",
units="m s-1",
Expand Down

0 comments on commit 011d31f

Please sign in to comment.