Skip to content

Commit

Permalink
Change climetlab to earthkit
Browse files Browse the repository at this point in the history
  • Loading branch information
b8raoult committed Sep 22, 2024
1 parent 5bac4f0 commit fdd42d6
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -158,3 +158,8 @@ cython_debug/
# and can be added to the global gitignore or merged into this file. For a more nuclear
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
#.idea/


*.onnx
*.grib
*.out
6 changes: 3 additions & 3 deletions utils/pangu-gfs-input.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

import sys

import climetlab as cml
import earthkit.data as ekd
import tqdm

date = sys.argv[1]
Expand All @@ -24,7 +24,7 @@
time = int(time)
time = f"{time:02d}"

gfs = cml.load_source(
gfs = ekd.from_source(
"url-pattern",
"https://data.rda.ucar.edu/ds084.1/{year}/{date}/"
"gfs.0p25.{date}{time}.f{step}.grib2",
Expand Down Expand Up @@ -62,7 +62,7 @@
).order_by(param=param_sfc)

print("Write", output)
out = cml.new_grib_output(output)
out = ekd.new_grib_output(output)

G = {"gh": 9.80665}
PARAM = {"gh": "z", "prmsl": "msl"}
Expand Down

0 comments on commit fdd42d6

Please sign in to comment.