Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add doppler-lidar-wind product #10

Merged
merged 1 commit into from
Feb 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion cloudnetpy_qc/quality.py
Original file line number Diff line number Diff line change
Expand Up @@ -251,6 +251,7 @@ class TestDataCoverage(Test):
Product.MWR_MULTI: datetime.timedelta(minutes=20),
Product.MWR_SINGLE: datetime.timedelta(minutes=2),
Product.WEATHER_STATION: datetime.timedelta(minutes=10),
Product.DOPPLER_LIDAR_WIND: datetime.timedelta(hours=1.5),
}
DEFAULT_RESOLUTION = datetime.timedelta(seconds=30)

Expand Down Expand Up @@ -400,7 +401,7 @@ class TestGlobalAttributes(Test):
def _instrument_product(self, product: Product):
return (
LEVELS[product] == "1b" and product != Product.MODEL
) or product == Product.MWR_L1C
) or product in (Product.MWR_L1C, Product.DOPPLER_LIDAR_WIND)

def _required_attrs(self, product: Product):
attrs = set(self.REQUIRED_ATTRS)
Expand Down Expand Up @@ -691,6 +692,7 @@ class TestInstrumentPid(Test):
Product.RADAR,
Product.DISDROMETER,
Product.DOPPLER_LIDAR,
Product.DOPPLER_LIDAR_WIND,
Product.WEATHER_STATION,
]

Expand Down
16 changes: 14 additions & 2 deletions cloudnetpy_qc/variables.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ class Product(Enum):
MODEL = "model"
WEATHER_STATION = "weather-station"
DOPPLER_LIDAR = "doppler-lidar"
DOPPLER_LIDAR_WIND = "doppler-lidar-wind"
RAIN_RADAR = "rain-radar"
# Level 1c
CATEGORIZE = "categorize"
Expand Down Expand Up @@ -51,6 +52,7 @@ def all(cls) -> set[Product]:
Product.MODEL: "1b",
Product.WEATHER_STATION: "1b",
Product.DOPPLER_LIDAR: "1b",
Product.DOPPLER_LIDAR_WIND: "1c",
Product.RAIN_RADAR: "1b",
Product.CATEGORIZE: "1c",
Product.MWR_L1C: "1c",
Expand Down Expand Up @@ -189,12 +191,22 @@ def time_units(nc: netCDF4.Dataset) -> str:
"uwind": Variable(
long_name="Zonal wind",
units="m s-1",
required=[Product.CATEGORIZE],
required=[Product.CATEGORIZE, Product.DOPPLER_LIDAR_WIND],
),
"uwind_raw": Variable(
long_name="Non-screened zonal wind",
units="m s-1",
required=[Product.DOPPLER_LIDAR_WIND],
),
"vwind": Variable(
long_name="Meridional wind",
units="m s-1",
required=[Product.CATEGORIZE],
required=[Product.CATEGORIZE, Product.DOPPLER_LIDAR_WIND],
),
"vwind_raw": Variable(
long_name="Non-screened meridional wind",
units="m s-1",
required=[Product.DOPPLER_LIDAR_WIND],
),
"q": Variable(
long_name="Specific humidity",
Expand Down
Loading