Skip to content

Commit 71f49a5

Browse files
authored
Skip test_freeu_enabled on MPS (#7570)
* Skip `test_freeu_enabled ` on MPS * Small fixes - import skip_mps correctly - disable all instances of test_freeu_enabled * Empty commit to trigger tests * Empty commit to trigger CI
1 parent 35db2fd commit 71f49a5

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

tests/pipelines/stable_diffusion/test_stable_diffusion.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@
5454
require_torch_2,
5555
require_torch_gpu,
5656
run_test_in_subprocess,
57+
skip_mps,
5758
slow,
5859
torch_device,
5960
)
@@ -639,6 +640,8 @@ def test_attention_slicing_forward_pass(self):
639640
def test_inference_batch_single_identical(self):
640641
super().test_inference_batch_single_identical(expected_max_diff=3e-3)
641642

643+
# MPS currently doesn't support ComplexFloats, which are required for freeU - see https://github.com/huggingface/diffusers/issues/7569.
644+
@skip_mps
642645
def test_freeu_enabled(self):
643646
components = self.get_dummy_components()
644647
sd_pipe = StableDiffusionPipeline(**components)

tests/pipelines/test_pipelines_common.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
from diffusers.schedulers import KarrasDiffusionSchedulers
4040
from diffusers.utils import logging
4141
from diffusers.utils.import_utils import is_accelerate_available, is_accelerate_version, is_xformers_available
42-
from diffusers.utils.testing_utils import CaptureLogger, require_torch, torch_device
42+
from diffusers.utils.testing_utils import CaptureLogger, require_torch, skip_mps, torch_device
4343

4444
from ..models.autoencoders.test_models_vae import (
4545
get_asym_autoencoder_kl_config,
@@ -125,6 +125,8 @@ def test_vae_tiling(self):
125125
zeros = torch.zeros(shape).to(torch_device)
126126
pipe.vae.decode(zeros)
127127

128+
# MPS currently doesn't support ComplexFloats, which are required for freeU - see https://github.com/huggingface/diffusers/issues/7569.
129+
@skip_mps
128130
def test_freeu_enabled(self):
129131
components = self.get_dummy_components()
130132
pipe = self.pipeline_class(**components)

0 commit comments

Comments
 (0)