Skip to content

Commit

Permalink
initial template, untested
Browse files Browse the repository at this point in the history
  • Loading branch information
blaylockbk committed Sep 8, 2023
1 parent 8048885 commit 0f0dfd6
Show file tree
Hide file tree
Showing 2 changed files with 46 additions and 0 deletions.
1 change: 1 addition & 0 deletions herbie/models/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
from .rtma import *
from .urma import *
from .hrdps import *
from .hafs import *

# ======================================================================
# Import Private Model Templates
Expand Down
45 changes: 45 additions & 0 deletions herbie/models/hafs.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
"""
A Herbie template for the HAFS model.
"""


class hafsa:
def template(self):
self.DESCRIPTION = "Hurricane Analysis and Forecast System"
self.DETAILS = {
"Homepage": "https://wpo.noaa.gov/the-hurricane-analysis-and-forecast-system-hafs/",
"Hurricane Forecast Improvement Program": "https://hfip.org/hafs",
}
self.PRODUCTS = {
"parent.atm": "?",
"parent.sat": "?",
"parent.swath": "?",
"storm.atm": "?",
"ww3": "?",
}
self.SOURCES = {
"nomads": f"https://nomads.ncep.noaa.gov/pub/data/nccf/com/hafs/prod/{self.model}.{self.date:%Y%m%d/%H}/{self.label}.{self.date:%Y%m%d%H}.{self.model}.{self.product}.f{self.fxx:02d}.grb2
}
self.EXPECT_IDX_FILE = "remote"
self.LOCALFILE = f"{self.get_remoteFileName}"


class hafsb:
def template(self):
self.DESCRIPTION = "Hurricane Analysis and Forecast System"
self.DETAILS = {
"Homepage": "https://wpo.noaa.gov/the-hurricane-analysis-and-forecast-system-hafs/",
"Hurricane Forecast Improvement Program": "https://hfip.org/hafs",
}
self.PRODUCTS = {
"parent.atm": "?",
"parent.sat": "?",
"parent.swath": "?",
"storm.atm": "?",
"ww3": "?",
}
self.SOURCES = {
"nomads": f"https://nomads.ncep.noaa.gov/pub/data/nccf/com/hafs/prod/{self.model}.{self.date:%Y%m%d/%H}/{self.label}.{self.date:%Y%m%d%H}.{self.model}.{self.product}.f{self.fxx:02d}.grb2
}
self.EXPECT_IDX_FILE = "remote"
self.LOCALFILE = f"{self.get_remoteFileName}"

0 comments on commit 0f0dfd6

Please sign in to comment.