diff options
author | brkirch <brkirch@users.noreply.github.com> | 2022-12-19 22:25:14 +0000 |
---|---|---|
committer | brkirch <brkirch@users.noreply.github.com> | 2022-12-21 02:30:00 +0000 |
commit | 35b1775b32a07f1b7c9dccad61f7aa77027a00fa (patch) | |
tree | 59f6583295d24b8f3c985da47d16089dfc5eeee4 /javascript/textualInversion.js | |
parent | 685f9631b56ff8bd43bce24ff5ce0f9a0e9af490 (diff) | |
download | stable-diffusion-webui-gfx803-35b1775b32a07f1b7c9dccad61f7aa77027a00fa.tar.gz stable-diffusion-webui-gfx803-35b1775b32a07f1b7c9dccad61f7aa77027a00fa.tar.bz2 stable-diffusion-webui-gfx803-35b1775b32a07f1b7c9dccad61f7aa77027a00fa.zip |
Use other MPS optimization for large q.shape[0] * q.shape[1]
Check if q.shape[0] * q.shape[1] is 2**18 or larger and use the lower memory usage MPS optimization if it is. This should prevent most crashes that were occurring at certain resolutions (e.g. 1024x1024, 2048x512, 512x2048).
Also included is a change to check slice_size and prevent it from being divisible by 4096 which also results in a crash. Otherwise a crash can occur at 1024x512 or 512x1024 resolution.
Diffstat (limited to 'javascript/textualInversion.js')
0 files changed, 0 insertions, 0 deletions