diff --git a/tests/ignite/engine/test_create_supervised.py b/tests/ignite/engine/test_create_supervised.py index 92ef6142b6b..4f07c95929e 100644 --- a/tests/ignite/engine/test_create_supervised.py +++ b/tests/ignite/engine/test_create_supervised.py @@ -447,7 +447,7 @@ def test_create_supervised_trainer_apex_error(): def mock_torch_cuda_amp_module(): with patch.dict( "sys.modules", - {"torch.amp": None, "torch.cuda.amp.grad_scaler": None, "torch.amp.autocast_mode": None}, + {"torch.amp": None, "torch.cuda.amp": None, "torch.amp.autocast_mode": None}, ): yield torch