Skip to content

Commit 462f1ee

Browse files
authored
Fix amp ddp test in Fabric (#16862)
1 parent 0130273 commit 462f1ee

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

tests/tests_fabric/plugins/precision/test_amp_integration.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -68,9 +68,7 @@ def after_backward(self, model):
6868
],
6969
)
7070
def test_amp(accelerator, precision, expected_dtype):
71-
# TODO: devices>1 fails with:
72-
# DDP expects same model across all ranks, but Rank 0 has 2 params, while rank 1 has inconsistent 1 params
73-
fabric = MixedPrecisionBoringFabric(accelerator=accelerator, precision=precision, devices=1)
71+
fabric = MixedPrecisionBoringFabric(accelerator=accelerator, precision=precision, devices=2, strategy="ddp_spawn")
7472
fabric.expected_dtype = expected_dtype
7573
fabric.run()
7674

0 commit comments

Comments
 (0)