Skip to content

Commit

Permalink
Add verify
Browse files Browse the repository at this point in the history
  • Loading branch information
dcherian committed Jan 29, 2025
1 parent 261dcce commit e1f3356
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
6 changes: 4 additions & 2 deletions modal_app.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,10 @@ def verify(ingest: Ingest, *, nsteps=5):
import dask

tic = time.time()
store = lib.get_zarr_store(ingest.store)
inrepo = xr.open_dataset(store, group=ingest.zarr_group, chunks=None, engine="zarr")
store = get_store(ingest.store)
inrepo = xr.open_dataset(
store, group=ingest.zarr_group, chunks=None, engine="zarr", consolidated=False
)
model = models.get_model(ingest.model)
timedim, stepdim = model.runtime_dim, model.step_dim

Expand Down
7 changes: 6 additions & 1 deletion modal_hrrr_icechunk.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import modal

from modal_app import applib, driver
from src.lib import WriteMode, utcnow
from src.lib import ReadMode, WriteMode, utcnow
from src.lib_modal import MODAL_FUNCTION_KWARGS

app = modal.App("hrrr-icehunk-ingest")
Expand Down Expand Up @@ -37,6 +37,11 @@ def main(mode: str, toml_file: str, since: str, till: str | None = None):
# driver(mode=mode, toml_file_path=file)


@app.function(**MODAL_FUNCTION_KWARGS, timeout=7200)
def hrrr_verify_icechunk():
driver(mode=ReadMode.VERIFY, toml_file_path="src/configs/hrrr-icechunk.toml")


@app.function(**MODAL_FUNCTION_KWARGS, timeout=7200)
def hrrr_backfill_icechunk_latest():
"""Run this "backfill" function wtih `modal run modal_hrrr.py::hrrr_backfill`."""
Expand Down

0 comments on commit e1f3356

Please sign in to comment.