Support per-regex diff-threshold predicates in the tensor comparator (#30654)

This commit is contained in:
fzyzcjy
2026-07-09 20:15:36 +08:00
committed by GitHub
parent 4153410477
commit 0d7e8cfb85
17 changed files with 799 additions and 42 deletions
@@ -63,7 +63,6 @@ def make_diff(
max_abs_diff: float = 0.0005,
mean_abs_diff: float = 0.0002,
abs_diff_percentiles: Optional[dict[int, float]] = None,
diff_threshold: float = 1e-3,
passed: bool = True,
) -> DiffInfo:
return DiffInfo(
@@ -78,7 +77,6 @@ def make_diff(
max_diff_coord=[2, 3],
baseline_at_max=1.0,
target_at_max=1.0005,
diff_threshold=diff_threshold,
passed=passed,
)