oceanmodeling / StormEvents

Python interfaces for observational data surrounding named storm events, born from @jreniel's ADCIRCpy

Home Page:https://stormevents.readthedocs.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Test fetching data for Hurricane Laura

moghimis opened this issue · comments

commented

@zacharyburnett

Would it be possible to test the system for https://en.wikipedia.org/wiki/Hurricane_Laura ?

If it is ok please your client py code for fetching COOPS and HWM here.

Thanks,
@moghimis

it seems that the issue here is that Laura 2020 and Marco 2020 are combined into a single flood event in the USGS HWM database:

usgs_flood_events(year=2020)
                                        name  year description      event_type event_status  coordinator instruments               last_updated  last_updated_by          start_date            end_date
usgs_id
301                    2020 Hurricane Isaias  2020         NaN       HURRICANE       ACTIVE         1001          [] 2020-07-31 11:47:44.480931            864.0 2020-07-31 05:00:00 2020-08-07 05:00:00
303         2020 TS Marco - Hurricane  Laura  2020         NaN       HURRICANE       ACTIVE          864          [] 2020-08-24 18:31:59.388708            864.0 2020-08-22 05:00:00 2020-08-30 05:00:00
304                     2020 Hurricane Sally  2020         NaN       HURRICANE       ACTIVE          864          [] 2020-09-13 13:15:24.843513            864.0 2020-09-13 05:00:00 2020-09-20 05:00:00
305                     2020 Hurricane Delta  2020         NaN       HURRICANE       ACTIVE          864          [] 2020-10-06 12:58:46.905258            864.0 2020-10-06 05:00:00 2020-10-13 05:00:00
308          Oregon Coastal Winter 2020-2021  2020         NaN  RIVERINE_FLOOD       ACTIVE          864          [] 2021-03-31 16:42:00.010533            864.0 2020-10-01 05:00:00 2021-04-15 05:00:00
309      Washington Coastal Winter 2020-2021  2020         NaN  RIVERINE_FLOOD       ACTIVE            1          [] 2021-06-11 21:54:02.343150            864.0 2020-10-01 05:00:00 2021-04-15 05:00:00

This means that Laura's HWM are under Marcos' entry in the storm table built by stormevents:

usgs_flood_storms(year=2020)
                                                usgs_name  year  nhc_name  year                                        description event_type event_status  coordinator instruments               last_updated  last_updated_by          start_date            end_date
nhc_code
AL092020                            2020 Hurricane Isaias  2020    ISAIAS  2020                                                NaN  HURRICANE       ACTIVE         1001          [] 2020-07-31 11:47:44.480931            864.0 2020-07-31 05:00:00 2020-08-07 05:00:00
AL142020                 2020 TS Marco - Hurricane  Laura  2020     MARCO  2020                                                NaN  HURRICANE       ACTIVE          864          [] 2020-08-24 18:31:59.388708            864.0 2020-08-22 05:00:00 2020-08-30 05:00:00
AL192020                             2020 Hurricane Sally  2020     SALLY  2020                                                NaN  HURRICANE       ACTIVE          864          [] 2020-09-13 13:15:24.843513            864.0 2020-09-13 05:00:00 2020-09-20 05:00:00
AL262020                             2020 Hurricane Delta  2020     DELTA  2020                                                NaN  HURRICANE       ACTIVE          864          [] 2020-10-06 12:58:46.905258            864.0 2020-10-06 05:00:00 2020-10-13 05:00:00

I didn't anticipate this, I'll go ahead and write a fix in the code for this case

@moghimis here is code that retrieves CO-OPS and HWM for Laura:

from pathlib import Path
from stormevents.stormevent import StormEvent

storm = StormEvent('laura', 2020)

flood_event = storm.flood_event
high_water_marks = flood_event.high_water_marks()

water_levels = storm.coops_product_within_isotach('water_level', wind_speed=34)

output_directory = Path('.')
high_water_marks.to_csv(output_directory / 'high_water_marks.csv')
water_levels.to_netcdf(output_directory / 'water_levels.nc')