mirror of
https://git.intern.spaceteamaachen.de/ALPAKA/SPATZ.git
synced 2025-06-10 01:55:59 +00:00
12 lines
270 B
Python
12 lines
270 B
Python
import numpy as np
|
|
|
|
from numpy.typing import ArrayLike
|
|
from typing import Any, Tuple
|
|
|
|
|
|
class Transform:
|
|
def apply(self, t: float, x: np.array):
|
|
y = self(t, x)
|
|
assert x.shape == y.shape, "Transform has to maintain the array's shape."
|
|
|
|
return y |