We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fb450e0 commit 0940c55Copy full SHA for 0940c55
LoopStructural/interpolators/supports/_3d_base_structured.py
@@ -1,3 +1,4 @@
1
+from LoopStructural.utils.exceptions import LoopException
2
import numpy as np
3
from LoopStructural.utils import getLogger
4
from . import SupportType
@@ -31,6 +32,10 @@ def __init__(
31
32
self.type = SupportType.BaseStructured
33
if np.any(step_vector == 0):
34
logger.warning(f"Step vector {step_vector} has zero values")
35
+ if np.any(nsteps == 0):
36
+ raise LoopException("nsteps cannot be zero")
37
+ if np.any(nsteps < 0):
38
+ raise LoopException("nsteps cannot be negative")
39
self._nsteps = np.array(nsteps, dtype=int) + 1
40
self._step_vector = np.array(step_vector)
41
self._origin = np.array(origin)
0 commit comments