fix naming

This commit is contained in:
2026-03-29 16:42:55 -07:00
parent c3bb34d248
commit f2be62ac46
51 changed files with 0 additions and 0 deletions

View File

@@ -0,0 +1,18 @@
import numpy as np
from tests.node_tests._shared import make_field
def test_fix_zero():
from backend.nodes.fix_zero import FixZero
node = FixZero()
field = make_field(data=np.array([[10, 20], [30, 40]], dtype=np.float64))
result_min, = node.process(field, method="min")
assert result_min.data.min() == 0.0
assert result_min.data.max() == 30.0
result_mean, = node.process(field, method="mean")
assert abs(result_mean.data.mean()) < 1e-10
result_median, = node.process(field, method="median")
assert abs(np.median(result_median.data)) < 1e-10