Skip to content

Commit e49407b

Browse files
committed
fixed bug in validation
1 parent 0d3ac76 commit e49407b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

dpbench/infrastructure/benchmark_validation.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ def relative_error(
9191
Returns: relative error.
9292
"""
9393
ref_norm = np.linalg.norm(ref)
94-
if ref_norm:
94+
if ref_norm == 0:
9595
val_norm = np.linalg.norm(val)
9696
if val_norm == 0:
9797
return 0.0

0 commit comments

Comments
 (0)