diff --git a/modules/patch.py b/modules/patch.py index 14f5852e..198e0100 100644 --- a/modules/patch.py +++ b/modules/patch.py @@ -181,6 +181,9 @@ class BrownianTreeNoiseSamplerPatched: @staticmethod def global_init(x, sigma_min, sigma_max, seed=None, transform=lambda x: x, cpu=False): + if ldm_patched.modules.model_management.directml_enabled: + cpu = True + t0, t1 = transform(torch.as_tensor(sigma_min)), transform(torch.as_tensor(sigma_max)) BrownianTreeNoiseSamplerPatched.transform = transform