Skip to content
This repository has been archived by the owner on Dec 20, 2024. It is now read-only.

Commit

Permalink
fix: import from utils
Browse files Browse the repository at this point in the history
  • Loading branch information
theissenhelen committed Jun 5, 2024
1 parent 2b7574c commit 70a48f2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions src/anemoi/models/interface/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
import uuid

import torch
from anemoi.utils.config import DotConfig
from anemoi.utils.config import DotDict
from hydra.utils import instantiate
from torch_geometric.data import HeteroData

Expand All @@ -22,7 +22,7 @@ class AnemoiModelInterface(torch.nn.Module):
"""Anemoi model on torch level."""

def __init__(
self, *, config: DotConfig, graph_data: HeteroData, statistics: dict, data_indices: dict, metadata: dict
self, *, config: DotDict, graph_data: HeteroData, statistics: dict, data_indices: dict, metadata: dict
) -> None:
super().__init__()
self.config = config
Expand Down
6 changes: 3 additions & 3 deletions src/anemoi/models/models/encoder_processor_decoder.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

import einops
import torch
from anemoi.utils.config import DotConfig
from anemoi.utils.config import DotDict
from hydra.utils import instantiate
from torch import Tensor
from torch import nn
Expand All @@ -32,7 +32,7 @@ class AnemoiModelEncProcDec(nn.Module):
def __init__(
self,
*,
config: DotConfig,
config: DotDict,
data_indices: dict,
graph_data: HeteroData,
) -> None:
Expand Down Expand Up @@ -119,7 +119,7 @@ def _assert_matching_indices(self, data_indices: dict) -> None:
self._internal_output_idx,
), f"Model indices must match {self._internal_input_idx} != {self._internal_output_idx}"

def _define_tensor_sizes(self, config: DotConfig) -> None:
def _define_tensor_sizes(self, config: DotDict) -> None:
# Define Sizes of different tensors
self._data_grid_size = self._graph_data[(self._graph_name_data, "to", self._graph_name_data)].ecoords_rad.shape[
0
Expand Down

0 comments on commit 70a48f2

Please sign in to comment.