Commit Graph

1776 Commits

Author SHA1 Message Date
brkirch
21effd629d Add workaround for using MPS with torchsde 2022-11-30 10:33:39 -05:00
Adi Eyal
a44994e2c9 Fixed incorrect negative prompt text in infotext
Previously only the first negative prompt in all_negative_prompts was
being used for infotext. This fixes that by selecting the index-th
negative prompt
2022-11-30 15:23:53 +02:00
Billy Cao
3a724e91a2 Change to steps of 8 2022-11-30 20:52:32 +08:00
wywywywy
7193814cf7
Added purpose of this hijack to comments 2022-11-29 19:22:53 +00:00
wywywywy
36c3613d16
Add autoencoder to sd_hijack 2022-11-29 17:40:02 +00:00
wywywywy
241cbc4d2f
Hijack VQModelInterface back to AutoEncoder 2022-11-29 17:38:16 +00:00
AUTOMATIC
4b3c5bc24b Merge remote-tracking branch 'pattontim/safetensors' 2022-11-29 17:06:15 +03:00
Billy Cao
9a8678f61e Support changing checkpoint and vae through override_settings 2022-11-29 11:11:29 +08:00
brkirch
98ca437edf Refactor and instead check if mps is being used, not availability 2022-11-28 21:18:51 -05:00
klimaleksus
67efee33a6
Make VAE step sequential to prevent VRAM spikes 2022-11-28 16:29:43 +05:00
AUTOMATIC
0b5dcb3d7c fix an error that happens when you type into prompt while switching model, put queue stuff into separate file 2022-11-28 09:00:10 +03:00
AUTOMATIC
0376da180c make it possible to save nai model using safetensors 2022-11-28 08:39:59 +03:00
AUTOMATIC
bb11bee22a if image on disk was deleted between being generated and request being completed, do use temporary dir to store it for the browser 2022-11-27 23:14:13 +03:00
AUTOMATIC
aa12dfada0 fix the bug that makes it impossible to send images to other tabs 2022-11-27 23:04:42 +03:00
AUTOMATIC1111
39827a3998
Merge pull request #4688 from parasi22/resolve-embedding-name-in-filewords
resolve [name] after resolving [filewords] in training
2022-11-27 22:46:49 +03:00
uservar
9146a5884c
Better should hijack inpainting detection 2022-11-27 19:11:50 +00:00
AUTOMATIC1111
9e78d2c419
Merge pull request #4416 from Keavon/cors-regex
Add CORS-allow policy launch argument using regex
2022-11-27 18:50:12 +03:00
AUTOMATIC1111
ef567b083c
Merge pull request #4919 from brkirch/deepbooru-fix
Fix support for devices other than CUDA in DeepBooru
2022-11-27 16:59:22 +03:00
AUTOMATIC1111
554787231a
Merge pull request #5117 from aliencaocao/fix_api_sampler_name
Fix api ignoring sampler_name settings
2022-11-27 16:51:47 +03:00
AUTOMATIC1111
b24aed0b69
Merge pull request #4960 from Hugo-Matias/master
fix null negative_prompt on get requests
2022-11-27 16:36:29 +03:00
AUTOMATIC
8c13f3a2a5 cherrypick from #4971 2022-11-27 16:35:35 +03:00
AUTOMATIC1111
c33b9a6da7
Merge pull request #4583 from NoCrypt/patch-1
Forcing HTTPS instead of HTTP for ngrok
2022-11-27 16:30:23 +03:00
AUTOMATIC
506d529d19 rework #5012 to also work for pictures dragged into the prompt and also add Clip skip + ENSD to parameters 2022-11-27 16:28:32 +03:00
cat
185ab3cbd1 Atomically rename saved image to avoid race condition with other processes. 2022-11-27 18:23:08 +05:00
Billy Cao
06ada734c7 Prevent warning on sampler_index if sampler_name is being used 2022-11-27 21:19:47 +08:00
Billy Cao
3cf93de24f Fix sampler_name for API requests are being ignored 2022-11-27 21:12:37 +08:00
AUTOMATIC1111
488f831d52
Merge pull request #5012 from Nandaka/master
Support NAI style exif in PNG Info for Send... buttons
2022-11-27 15:57:50 +03:00
AUTOMATIC1111
9ec0a41a58
Merge pull request #4977 from sena-nana/master
Fix API img2img not accepting bare base64 strings
2022-11-27 15:54:39 +03:00
AUTOMATIC
dac9b6f15d add safetensors support for model merging #4869 2022-11-27 15:51:29 +03:00
AUTOMATIC
6074175faa add safetensors to requirements 2022-11-27 14:46:40 +03:00
AUTOMATIC1111
f108782e30
Merge pull request #4930 from Narsil/allow_to_load_safetensors_file
Supporting `*.safetensors` format.
2022-11-27 14:36:55 +03:00
AUTOMATIC1111
a89d7f4f38
Merge pull request #4913 from dtlnor/deprecated-deepdanbooru-patch
Remove cmd args requirement for deepdanbooru
2022-11-27 14:19:32 +03:00
AUTOMATIC1111
eb08550108
Merge pull request #4663 from xucj98/draft
fix the model name error of Real-ESRGAN in the opts default value
2022-11-27 14:16:45 +03:00
AUTOMATIC1111
ca8c764af8
Merge pull request #4986 from mcmonkey4eva/add-model-name
add model_name pattern for saving
2022-11-27 13:58:34 +03:00
AUTOMATIC1111
8de897b3da
Merge pull request #5085 from MrCheeze/sd-2.0-automatic-2
no-half support for SD 2.0
2022-11-27 13:54:08 +03:00
AUTOMATIC1111
01f2ed6844
Merge pull request #5065 from JaySmithWpg/vram-leak
#3449 - VRAM leak when switching to/from inpainting checkpoint
2022-11-27 13:52:14 +03:00
AUTOMATIC1111
151e2cc627
Merge pull request #4461 from brkirch/face-restoration-device-fix
Fix setting device for GFPGAN and CodeFormer
2022-11-27 13:48:25 +03:00
AUTOMATIC1111
cc90dcc933
Merge pull request #4918 from brkirch/pytorch-fixes
Fixes for PyTorch 1.12.1 when using MPS
2022-11-27 13:47:01 +03:00
AUTOMATIC
10923f9b3a calculate dictionary for sampler names only once 2022-11-27 13:43:10 +03:00
AUTOMATIC
40ca34b837 fix for broken sampler selection in img2img and xy plot #4860 #4909 2022-11-27 13:17:39 +03:00
AUTOMATIC
5b2c316890 eliminate duplicated code from #5095 2022-11-27 13:08:54 +03:00
AUTOMATIC1111
997ac57020
Merge pull request #5095 from mlmcgoogan/master
torch.cuda.empty_cache() defaults to cuda:0 device unless explicitly …
2022-11-27 12:56:02 +03:00
AUTOMATIC1111
6df4945718
Merge branch 'master' into DPM++SDE 2022-11-27 12:54:45 +03:00
AUTOMATIC
b48b7999c8 Merge remote-tracking branch 'flamelaw/master' 2022-11-27 12:19:59 +03:00
AUTOMATIC
b006382784 serve images from where they are saved instead of a temporary directory
add an option to choose a different temporary directory in the UI
add an option to cleanup the selected temporary directory at startup
2022-11-27 11:52:53 +03:00
Billy Cao
349f0461ec
Merge branch 'master' into support_any_resolution 2022-11-27 12:39:31 +08:00
Matthew McGoogan
c67c40f983 torch.cuda.empty_cache() defaults to cuda:0 device unless explicitly set otherwise first. Updating torch_gc() to use the device set by --device-id if specified to avoid OOM edge cases on multi-GPU systems. 2022-11-26 23:25:16 +00:00
MrCheeze
1e506657e1 no-half support for SD 2.0 2022-11-26 13:28:44 -05:00
AUTOMATIC
b5050ad207 make SD2 compatible with --medvram setting 2022-11-26 20:52:16 +03:00
flamelaw
755df94b2a set TI AdamW default weight decay to 0 2022-11-27 00:35:44 +09:00
AUTOMATIC
64c7b7975c restore hypernetworks to seemingly working state 2022-11-26 16:45:57 +03:00
AUTOMATIC
1123f52cad add 1024 module for hypernets for the new open clip 2022-11-26 16:37:37 +03:00
AUTOMATIC
ce6911158b Add support Stable Diffusion 2.0 2022-11-26 16:10:46 +03:00
Jay Smith
c833d5bfaa fixes #3449 - VRAM leak when switching to/from inpainting model 2022-11-25 20:15:11 -06:00
xucj98
263b323de1
Merge branch 'AUTOMATIC1111:master' into draft 2022-11-25 17:07:00 +08:00
Tiago F. Santos
a2ae5a6555 [interrogator] mkdir check 2022-11-24 13:04:45 +00:00
Sena
fcd75bd874
Fix other apis 2022-11-24 13:10:40 +08:00
Nandaka
904121fecc Support NAI exif for PNG Info 2022-11-24 02:39:09 +00:00
Alex "mcmonkey" Goodwin
ffcbbcf385 add filename santization
Probably redundant, considering the model name *is* a filename, but I suppose better safe than sorry.
2022-11-23 06:44:20 -08:00
Alex "mcmonkey" Goodwin
6001684be3 add model_name pattern for saving 2022-11-23 06:35:44 -08:00
flamelaw
1bd57cc979 last_layer_dropout default to False 2022-11-23 20:21:52 +09:00
flamelaw
d2c97fc3fe fix dropout, implement train/eval mode 2022-11-23 20:00:00 +09:00
Billy Cao
adb6cb7619 Patch UNet Forward to support resolutions that are not multiples of 64
Also modifed the UI to no longer step in 64
2022-11-23 18:11:24 +08:00
Sena
75b67eebf2
Fix bare base64 not accept 2022-11-23 17:43:58 +08:00
flamelaw
89d8ecff09 small fixes 2022-11-23 02:49:01 +09:00
Tim Patton
ac90cf38c6 safetensors optional for now 2022-11-22 10:13:07 -05:00
uservar
0a01f50891
Add DPM++ SDE sampler 2022-11-22 14:24:50 +00:00
Rogerooo
c27a973c82 fix null negative_prompt on get requests
Small typo that causes a bug when returning negative prompts from the get request.
2022-11-22 14:02:59 +00:00
Tiago F. Santos
745f1e8f80 [CLIP interrogator] use local file, if available 2022-11-22 12:48:25 +00:00
Tim Patton
210cb4c128 Use GPU for loading safetensors, disable export 2022-11-21 16:40:18 -05:00
Tim Patton
162fef394f Patch line ui endings 2022-11-21 10:50:57 -05:00
Nicolas Patry
0efffbb407 Supporting *.safetensors format.
If a model file exists with extension `.safetensors` then we can load it
more safely than with PyTorch weights.
2022-11-21 14:04:25 +01:00
brkirch
563ea3f6ff Change .cuda() to .to(devices.device) 2022-11-21 02:56:00 -05:00
brkirch
e247b7400a Add fixes for PyTorch 1.12.1
Fix typo "MasOS" -> "macOS"

If MPS is available and PyTorch is an earlier version than 1.13:
* Monkey patch torch.Tensor.to to ensure all tensors sent to MPS are contiguous
* Monkey patch torch.nn.functional.layer_norm to ensure input tensor is contiguous (required for this program to work with MPS on unmodified PyTorch 1.12.1)
2022-11-21 02:07:19 -05:00
dtlnor
9ae30b3450 remove cmd args requirement for deepdanbooru 2022-11-21 12:53:55 +09:00
flamelaw
5b57f61ba4 fix pin_memory with different latent sampling method 2022-11-21 10:15:46 +09:00
Tim Patton
637815632f Generalize SD torch load/save to implement safetensor merging compat 2022-11-20 13:36:05 -05:00
AUTOMATIC1111
828438b4a1
Merge pull request #4120 from aliencaocao/enable-override-hypernet
Enable override_settings to take effect for hypernetworks
2022-11-20 16:49:06 +03:00
AUTOMATIC
c81d440d87 moved deepdanbooru to pure pytorch implementation 2022-11-20 16:39:20 +03:00
flamelaw
2d22d72cda fix random sampling with pin_memory 2022-11-20 16:14:27 +09:00
flamelaw
a4a5735d0a remove unnecessary comment 2022-11-20 12:38:18 +09:00
flamelaw
bd68e35de3 Gradient accumulation, autocast fix, new latent sampling method, etc 2022-11-20 12:35:26 +09:00
Tim Patton
ac7ecd2d84 Label and load SD .safetensors model files 2022-11-19 14:49:22 -05:00
Keavon Chambers
2f90496b19
Merge branch 'master' into cors-regex 2022-11-19 10:34:31 -08:00
AUTOMATIC
3596af0749 Add API for scripts to add elements anywhere in UI. 2022-11-19 19:10:28 +03:00
AUTOMATIC1111
ccd73fc186
Merge pull request #4717 from papuSpartan/security
Add --server-name to the list of arguments considered insecure
2022-11-19 15:31:09 +03:00
AUTOMATIC1111
41e242b220
Merge pull request #4733 from MaikoTan/api-authorization
feat: add http basic authentication for api
2022-11-19 15:20:03 +03:00
AUTOMATIC
5a6387e189 make it possible to change models etc by editing options using API 2022-11-19 15:15:24 +03:00
Maiko Tan
336c341a7c
Merge branch 'master' into api-authorization 2022-11-19 20:13:07 +08:00
AUTOMATIC1111
84a6f211d4
Merge pull request #4358 from bamarillo/master
[API][Feature] Add Skip endpoint
2022-11-19 14:50:02 +03:00
AUTOMATIC1111
4b22ec4138
Merge pull request #4759 from dtlnor/kill-gradio-progress-bar
Hide Gradio progress again
2022-11-19 13:49:21 +03:00
AUTOMATIC
413c077969 prevent StableDiffusionProcessingImg2Img changing image_mask field as an alternative solution to #4765 2022-11-19 13:48:59 +03:00
AUTOMATIC1111
89daf778fb
Merge pull request #4812 from space-nuko/feature/interrupt-preprocessing
Add interrupt button to preprocessing
2022-11-19 13:26:33 +03:00
AUTOMATIC1111
fe03f9903c
Merge pull request #4819 from killfrenzy96/master
Cleanly undo circular hijack to fix tiling getting stuck on #4818
2022-11-19 13:26:03 +03:00
AUTOMATIC
617c5b486f make it possible for StableDiffusionProcessing to accept multiple different negative prompts in a batch 2022-11-19 13:23:25 +03:00
AUTOMATIC1111
e35d8b493f
Merge pull request #4778 from leppie/fix_unbounded_prompt_growth
Fix unbounded prompt growth/determinism in scripts that loop
2022-11-19 12:52:55 +03:00
AUTOMATIC
0d702930b0 renamed Inpainting strength infotext to Conditional mask weight, made it only appear if using inpainting model, made it possible to read the setting from it using the blue arrow button 2022-11-19 12:47:52 +03:00
Muhammad Rizqi Nur
8662b5e57f Merge branch 'a1111' into vae-fix-none 2022-11-19 16:38:21 +07:00
AUTOMATIC1111
ff35ae9abb
Merge pull request #4679 from Eugenii10/inpaint-strength-to-infotext
Add 'Inpainting strength' to the 'generation_params' of 'infotext' (params.txt or png chunks)
2022-11-19 12:24:44 +03:00
AUTOMATIC1111
aee611adb8
Merge pull request #4646 from mrauhu/force-update-extensions
Fix: `error: Your local changes to the following files would be overwritten by merge` when trying to update extensions in WSL2 Docker
2022-11-19 12:22:51 +03:00
AUTOMATIC1111
5bfef6e063
Merge pull request #4844 from R-N/vae-misc
Remove no longer necessary code from VAE selector, fix #4651
2022-11-19 12:21:22 +03:00
AUTOMATIC
cdc8020d13 change StableDiffusionProcessing to internally use sampler name instead of sampler index 2022-11-19 12:01:51 +03:00
Muhammad Rizqi Nur
45dca0562e Merge branch 'a1111' into vae-fix-none 2022-11-19 15:21:00 +07:00
Muhammad Rizqi Nur
f1bdf2b15f Merge branch 'a1111' into vae-misc 2022-11-19 15:20:07 +07:00
AUTOMATIC
d9fd4525a5 change text for sd_vae_as_default that makes more sense to me 2022-11-19 11:09:44 +03:00
AUTOMATIC1111
3951806058
Merge pull request #4842 from R-N/vae-as-default
Option to use selected VAE as default fallback instead of primary option
2022-11-19 10:59:42 +03:00
Muhammad Rizqi Nur
c8f7b5cdd7 Misc
Misc
2022-11-19 12:04:12 +07:00
Muhammad Rizqi Nur
271fd2d700 More verbose messages 2022-11-19 12:02:50 +07:00
Muhammad Rizqi Nur
2c5ca706a7 Remove no longer necessary parts and add vae_file safeguard 2022-11-19 12:01:41 +07:00
Muhammad Rizqi Nur
0663706d44 Option to use selected VAE as default fallback instead of primary option 2022-11-19 11:49:06 +07:00
Muhammad Rizqi Nur
028b67b635 Use underscore naming for "private" functions in sd_vae 2022-11-19 11:47:54 +07:00
Muhammad Rizqi Nur
9fdc343dca Fix model caching requiring deepcopy 2022-11-19 11:44:37 +07:00
Muhammad Rizqi Nur
c7be83bf02 Misc
Misc
2022-11-19 11:44:37 +07:00
Muhammad Rizqi Nur
abc1e79a5d Fix base VAE caching was done after loading VAE, also add safeguard 2022-11-19 11:41:41 +07:00
Muhammad Rizqi Nur
8ab4927452 Fix model wasn't restored even when choosing "None" 2022-11-19 11:41:21 +07:00
killfrenzy96
17e4432820 cleanly undo circular hijack #4818 2022-11-18 21:22:55 +11:00
space-nuko
c8c40c8a64 Add interrupt button to preprocessing 2022-11-17 18:05:29 -08:00
brkirch
a5106a7cdc Remove extra .to(device) 2022-11-17 00:08:45 -05:00
brkirch
abfa22c16f Revert "MPS Upscalers Fix"
This reverts commit 768b95394a8500da639b947508f78296524f1836.
2022-11-17 00:08:21 -05:00
Llewellyn Pritchard
9bbe1e3c2e Fix unbounded prompt growth scripts that loop 2022-11-16 19:19:00 +02:00
dtlnor
72b52fbb77 add css override 2022-11-16 13:08:03 +09:00
Maiko Sinkyaet Tan
8f2ff861d3
feat: add http basic authentication for api 2022-11-15 16:12:34 +08:00
papuSpartan
3405acc6a4 Give --server-name priority over --listen and add check for --server-name in addition to --share and --listen 2022-11-14 14:07:13 -06:00
KEV
40ae95d532 Fix retrieving value for 'x/y plot' script. 2022-11-14 18:05:59 +10:00
parasi
9a1aff645a resolve [name] after resolving [filewords] in training 2022-11-13 13:49:28 -06:00
Ryan Voots
671c0e42b4 Fix docker tmp/ and extensions/ handling for docker. might also work for symlinks 2022-11-13 13:39:41 -05:00
KEV
6fa891b934 Add 'Inpainting strength' to the 'generation_params' dictionary of 'infotext' which is saved into the 'params.txt' or png chunks.
Value appears only if 'Denoising strength' appears too.
2022-11-14 00:25:38 +10:00
Xu Cuijie
d20dbe47e0 fix the model name error of Real-ESRGAN in the opts default value 2022-11-13 10:31:03 +08:00
Mrau Hu
d671d1d45d Fix: error: Your local changes to the following files would be overwritten by merge when run pull() method,
because WSL2 Docker set 755 file permissions instead of 644, this results to the error.

Updated `Extension` class: replaced `pull()` with `fetch_and_reset_hard()` method.

Updated `apply_and_restart()` function: replaced `ext.pull()` with `ext.fetch_and_reset_hard()` function.
2022-11-12 21:44:42 +03:00
brkirch
f4a488f585 Set device for facelib/facexlib and gfpgan
* FaceXLib/FaceLib doesn't pass the device argument to RetinaFace but instead chooses one itself and sets it to a global - in order to use a device other than its internally chosen default it is necessary to manually replace the default value
* The GFPGAN constructor needs the device argument to work with MPS or a CUDA device ID that differs from the default
2022-11-12 03:34:13 -05:00
AUTOMATIC
98947d173e run installers for newly installed extensions 2022-11-12 11:11:47 +03:00
AUTOMATIC
a1a376331c make existing script loading and new preload code use same code for loading modules
limit extension preload scripts to just one file named preload.py
2022-11-12 10:56:06 +03:00
AUTOMATIC1111
e5690d0bf2
Merge pull request #4488 from d8ahazard/ExtensionPreload
Add option to preload extensions
2022-11-12 10:29:15 +03:00
AUTOMATIC
0ab0a50f9a change formatting to match the main program in devices.py 2022-11-12 10:00:49 +03:00
AUTOMATIC
c62d17aee3 use the new devices.has_mps() function in register_buffer for DDIM/PLMS fix for OSX 2022-11-12 10:00:22 +03:00
源文雨
1130d5df66
Update devices.py 2022-11-12 11:09:28 +08:00
源文雨
76ab31e188 Fix wrong mps selection below MasOS 12.3 2022-11-12 11:02:40 +08:00
AUTOMATIC
7ba3923d5b move DDIM/PLMS fix for OSX out of the file with inpainting code. 2022-11-11 18:20:18 +03:00
AUTOMATIC1111
bb2e2c82ce
Merge pull request #4233 from thesved/patch-1
Make DDIM and PLMS work on Mac OS
2022-11-11 18:01:58 +03:00
AUTOMATIC1111
b8a2e38758
Merge pull request #4543 from tong-zeng/master
Fix a bug in list_files_with_name
2022-11-11 18:00:13 +03:00
NoCrypt
6165f07e74
Merge branch 'master' into patch-1 2022-11-11 21:14:10 +07:00
AUTOMATIC1111
e666220ee4
Merge pull request #4514 from cluder/4448_fix_ckpt_cache
#4448 fix checkpoint cache usage
2022-11-11 16:04:17 +03:00
AUTOMATIC1111
6a2044f566
Merge pull request #4563 from JingShing/master
Add username and password in ngrok
2022-11-11 15:57:24 +03:00
AUTOMATIC1111
ec95ced6fb
Merge pull request #4573 from liamkerr/4415-update-generation-info
4415 update generation info
2022-11-11 15:51:14 +03:00
AUTOMATIC1111
73776907ec
Merge pull request #4117 from TinkTheBoush/master
Adding optional tag shuffling for training
2022-11-11 15:46:20 +03:00
AUTOMATIC1111
6585cba200
Merge pull request #4395 from snowmeow2/master
Add DeepDanbooru to the interrogate API
2022-11-11 15:41:30 +03:00
KyuSeok Jung
a1e271207d
Update dataset.py 2022-11-11 10:56:53 +09:00
NoCrypt
c556d34523
Forcing HTTPS instead of HTTP for ngrok
For security reason.
2022-11-11 08:54:51 +07:00
KyuSeok Jung
b19af67d29
Update dataset.py 2022-11-11 10:54:19 +09:00
KyuSeok Jung
0959907f87
adding tag dropout option 2022-11-11 10:31:14 +09:00