diff --git a/setup.cfg b/setup.cfg index 916c7639..64ffe0bf 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,6 +1,6 @@ [metadata] name = yt_idefix -version = 0.13.3 +version = 0.13.4 description = An extension module for yt, adding a frontend for Idefix long_description = file: README.md long_description_content_type = text/markdown diff --git a/yt_idefix/__init__.py b/yt_idefix/__init__.py index b9ee9e25..7856e800 100644 --- a/yt_idefix/__init__.py +++ b/yt_idefix/__init__.py @@ -2,4 +2,4 @@ # immediately after `import yt.extensions.idefix` from yt_idefix.api import * -__version__ = "0.13.3" +__version__ = "0.13.4" diff --git a/yt_idefix/data_structures.py b/yt_idefix/data_structures.py index 8795c870..0905e308 100644 --- a/yt_idefix/data_structures.py +++ b/yt_idefix/data_structures.py @@ -8,7 +8,7 @@ from abc import ABC, abstractmethod from functools import cached_property from importlib.metadata import version -from typing import Literal, Sequence +from typing import Literal import inifix import numpy as np @@ -147,7 +147,14 @@ def _cell_centers(self): # with unit "code_length" and dtype float64 ... - def _icoords_to_fcoords(self, icoords, ires, axes: Sequence[int] = (0, 1, 2)): + def _icoords_to_fcoords( + self, + icoords: np.ndarray, + ires: np.ndarray, + axes: tuple[int, ...] | None = None, + ): + if axes is None: + axes = (0, 1, 2) # this is needed to support projections coords = np.empty(icoords.shape, dtype="f8") cell_widths = np.empty(icoords.shape, dtype="f8")