diff options
author | AUTOMATIC1111 <16777216c@gmail.com> | 2023-08-13 17:28:49 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-08-13 17:28:49 +0000 |
commit | 9cd0475c0823abc289125e4095b0ba5256f71538 (patch) | |
tree | 465aa091d5302761c39455049d3aca0d2b83c817 /modules/mac_specific.py | |
parent | 8452708560586e2d5047c7d8df2b4ba642d94dac (diff) | |
parent | 2035cbbd5d6e7678450c701fce1a5de7d8bd7084 (diff) | |
download | stable-diffusion-webui-gfx803-9cd0475c0823abc289125e4095b0ba5256f71538.tar.gz stable-diffusion-webui-gfx803-9cd0475c0823abc289125e4095b0ba5256f71538.tar.bz2 stable-diffusion-webui-gfx803-9cd0475c0823abc289125e4095b0ba5256f71538.zip |
Merge pull request #12526 from brkirch/mps-adjust-sub-quad
Fixes for `git checkout`, MPS/macOS fixes and optimizations
Diffstat (limited to 'modules/mac_specific.py')
-rw-r--r-- | modules/mac_specific.py | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/modules/mac_specific.py b/modules/mac_specific.py index bce527cc..89256c5b 100644 --- a/modules/mac_specific.py +++ b/modules/mac_specific.py @@ -52,9 +52,6 @@ def cumsum_fix(input, cumsum_func, *args, **kwargs): if has_mps: - # MPS fix for randn in torchsde - CondFunc('torchsde._brownian.brownian_interval._randn', lambda _, size, dtype, device, seed: torch.randn(size, dtype=dtype, device=torch.device("cpu"), generator=torch.Generator(torch.device("cpu")).manual_seed(int(seed))).to(device), lambda _, size, dtype, device, seed: device.type == 'mps') - if platform.mac_ver()[0].startswith("13.2."): # MPS workaround for https://github.com/pytorch/pytorch/issues/95188, thanks to danieldk (https://github.com/explosion/curated-transformers/pull/124) CondFunc('torch.nn.functional.linear', lambda _, input, weight, bias: (torch.matmul(input, weight.t()) + bias) if bias is not None else torch.matmul(input, weight.t()), lambda _, input, weight, bias: input.numel() > 10485760) |