Skip to content

Commit

Permalink
No public description
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 641387716
  • Loading branch information
langmore authored and NeuralGCM authors committed Jun 7, 2024
1 parent 4ad8faf commit 114d3a5
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions neuralgcm/forcings.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
from __future__ import annotations

import functools
import logging
from typing import Any, Optional, Union

from dinosaur import coordinate_systems
Expand Down Expand Up @@ -47,6 +48,8 @@
# handle errors, if we like this, then make public.
_FORCING_ERRORS = []

# pylint: disable=logging-fstring-interpolation


class ForcingDataError(Exception):
"""To raise when an error is encountered with forcing data."""
Expand Down Expand Up @@ -102,6 +105,7 @@ def __init__(
check_sim_time_errors: bool = False,
name: Optional[str] = None,
):
logging.info(f'[NGCM] Initializing DynamicDataForcing with {dt_tolerance=}')
# TODO(shoyer): remove data_time_step entirely, once we're sure that no
# saved checkpoints that we care about will break.
del data_time_step # no longer used
Expand Down Expand Up @@ -183,6 +187,7 @@ def __init__(
time_axis: int = 0,
name: Optional[str] = None,
):
logging.info('[NGCM] Initializing PersistenceDataForcing')
super().__init__(name=name)
self.time_axis = time_axis
self.nondim_transform_fn = transforms.NondimensionalizeTransform(
Expand Down

0 comments on commit 114d3a5

Please sign in to comment.