Skip to content

Commit f044fa2

Browse files
feginpytorchmergebot
authored andcommitted
[AsyncTP] Use assertEqual instead of allClose for bf16 tests (pytorch#162041)
The async tp result and regular MM result are very close. If we adjust the allclose threshold, the test succeeds. This seems to indicate that the error is from numerical error of low precision. Pull Request resolved: pytorch#162041 Approved by: https://github.com/danielvegamyhre, https://github.com/ngimel ghstack dependencies: pytorch#162040
1 parent a92773e commit f044fa2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

test/distributed/test_symmetric_memory.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -558,7 +558,7 @@ def test_fused_scaled_matmul_reduce_scatter(
558558
)
559559

560560
assert outputs[0].stride() == outputs[1].stride()
561-
assert torch.allclose(outputs[0], outputs[1]), (outputs[0], outputs[1])
561+
self.assertEqual(outputs[0], outputs[1])
562562

563563
@runOnRocmArch(MI300_ARCH)
564564
@parametrize("dim", [0, 1, 2])

0 commit comments

Comments
 (0)