Skip to content

Commit 7ef5dab

Browse files
faaanyDN6
andauthored
Update tests/pipelines/deepfloyd_if/test_if.py
Co-authored-by: Dhruv Nair <[email protected]>
1 parent f73a38a commit 7ef5dab

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

tests/pipelines/deepfloyd_if/test_if.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,8 @@ def get_dummy_inputs(self, device, seed=0):
5858
def test_save_load_optional_components(self):
5959
self._test_save_load_optional_components()
6060

61-
@require_non_cpu
61+
@unittest.skipIf(torch_device not in ["cuda", "xpu"], reason="float16 requires CUDA or XPU")
62+
@require_accelerator
6263
def test_save_load_float16(self):
6364
# Due to non-determinism in save load of the hf-internal-testing/tiny-random-t5 text encoder
6465
super().test_save_load_float16(expected_max_diff=1e-1)

0 commit comments

Comments
 (0)