Skip to content

Commit 6f2fe45

Browse files
authored
[Unity][UnitTest] Increase atol to resolve flaky CI failure (#16340)
The `tests/python/relax/test_frontend_onnx.py::test_attention` unit test currently has sporadic failures (5/200 executions), which can cause failures for unrelated changes (e.g. [PR#16304](#16304), [CI link](https://ci.tlcpack.ai/blue/organizations/jenkins/tvm-unity/detail/PR-16304/3/pipeline)). This commit specifies a tolerance to use for comparisons, to avoid these spurious CI failures.
1 parent ec542da commit 6f2fe45

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

tests/python/relax/test_frontend_onnx.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1226,6 +1226,8 @@ def verify_attention(
12261226
"mask_index": mask_index,
12271227
"relative_position_bias": relative_position_bias,
12281228
},
1229+
# Maximum observed delta from 500 iterations was 2e-4.
1230+
atol=1e-3,
12291231
)
12301232
# "present" output should be nullptr when the "past" input isn't included,
12311233
# but ort requires an output shape to be specified?

0 commit comments

Comments
 (0)