@ -28,10 +28,12 @@ Check the [custom scripts](https://github.com/AUTOMATIC1111/stable-diffusion-web
- CodeFormer, face restoration tool as an alternative to GFPGAN
- CodeFormer, face restoration tool as an alternative to GFPGAN
- RealESRGAN, neural network upscaler
- RealESRGAN, neural network upscaler
- ESRGAN, neural network upscaler with a lot of third party models
- ESRGAN, neural network upscaler with a lot of third party models
- SwinIR, neural network upscaler
- SwinIR and Swin2SR([see here](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/2092)), neural network upscalers
- LDSR, Latent diffusion super resolution upscaling
- LDSR, Latent diffusion super resolution upscaling
- Resizing aspect ratio options
- Resizing aspect ratio options
- Sampling method selection
- Sampling method selection
- Adjust sampler eta values (noise multiplier)
- More advanced noise setting options
- Interrupt processing at any time
- Interrupt processing at any time
- 4GB video card support (also reports of 2GB working)
- 4GB video card support (also reports of 2GB working)
- Correct seeds for batches
- Correct seeds for batches
@ -67,6 +69,7 @@ Check the [custom scripts](https://github.com/AUTOMATIC1111/stable-diffusion-web
- also supports weights for prompts: `a cat :1.2 AND a dog AND a penguin :2.2`
- also supports weights for prompts: `a cat :1.2 AND a dog AND a penguin :2.2`
- No token limit for prompts (original stable diffusion lets you use up to 75 tokens)
- No token limit for prompts (original stable diffusion lets you use up to 75 tokens)
- DeepDanbooru integration, creates danbooru style tags for anime prompts (add --deepdanbooru to commandline args)
- DeepDanbooru integration, creates danbooru style tags for anime prompts (add --deepdanbooru to commandline args)
- [xformers](https://github.com/AUTOMATIC1111/stable-diffusion-webui/wiki/Xformers), major speed increase for select cards: (add --xformers to commandline args)
## Installation and Running
## Installation and Running
Make sure the required [dependencies](https://github.com/AUTOMATIC1111/stable-diffusion-webui/wiki/Dependencies) are met and follow the instructions available for both [NVidia](https://github.com/AUTOMATIC1111/stable-diffusion-webui/wiki/Install-and-Run-on-NVidia-GPUs) (recommended) and [AMD](https://github.com/AUTOMATIC1111/stable-diffusion-webui/wiki/Install-and-Run-on-AMD-GPUs) GPUs.
Make sure the required [dependencies](https://github.com/AUTOMATIC1111/stable-diffusion-webui/wiki/Dependencies) are met and follow the instructions available for both [NVidia](https://github.com/AUTOMATIC1111/stable-diffusion-webui/wiki/Install-and-Run-on-NVidia-GPUs) (recommended) and [AMD](https://github.com/AUTOMATIC1111/stable-diffusion-webui/wiki/Install-and-Run-on-AMD-GPUs) GPUs.
@ -116,13 +119,17 @@ The documentation was moved from this README over to the project's [wiki](https:
"Highres. fix":"Use a two step process to partially create an image at smaller resolution, upscale, and then improve details in it without changing composition",
"Highres. fix":"Use a two step process to partially create an image at smaller resolution, upscale, and then improve details in it without changing composition",
"Scale latent":"Uscale the image in latent space. Alternative is to produce the full image from latent representation, upscale that, and then move it back to latent space.",
"Scale latent":"Uscale the image in latent space. Alternative is to produce the full image from latent representation, upscale that, and then move it back to latent space.",
"Eta noise seed delta":"If this values is non-zero, it will be added to seed and used to initialize RNG for noises when using samplers with Eta. You can use this to produce even more variation of images, or you can use this to match images of other software if you know what you are doing.",
"Do not add watermark to images":"If this option is enabled, watermark will not be added to created images. Warning: if you do not add watermark, you may be bevaing in an unethical manner.",
@ -29,6 +30,7 @@ parser.add_argument("--no-half-vae", action='store_true', help="do not switch th
parser.add_argument("--no-progressbar-hiding",action='store_true',help="do not hide progressbar in gradio UI (we hide it because it slows down ML if you have hardware acceleration in browser)")
parser.add_argument("--no-progressbar-hiding",action='store_true',help="do not hide progressbar in gradio UI (we hide it because it slows down ML if you have hardware acceleration in browser)")
parser.add_argument("--max-batch-count",type=int,default=16,help="maximum batch count value for the UI")
parser.add_argument("--max-batch-count",type=int,default=16,help="maximum batch count value for the UI")
parser.add_argument("--embeddings-dir",type=str,default=os.path.join(script_path,'embeddings'),help="embeddings directory for textual inversion (default: embeddings)")
parser.add_argument("--embeddings-dir",type=str,default=os.path.join(script_path,'embeddings'),help="embeddings directory for textual inversion (default: embeddings)")
parser.add_argument("--allow-code",action='store_true',help="allow custom script execution from webui")
parser.add_argument("--allow-code",action='store_true',help="allow custom script execution from webui")
parser.add_argument("--medvram",action='store_true',help="enable stable diffusion model optimizations for sacrificing a little speed for low VRM usage")
parser.add_argument("--medvram",action='store_true',help="enable stable diffusion model optimizations for sacrificing a little speed for low VRM usage")
parser.add_argument("--lowvram",action='store_true',help="enable stable diffusion model optimizations for sacrificing a lot of speed for very low VRM usage")
parser.add_argument("--lowvram",action='store_true',help="enable stable diffusion model optimizations for sacrificing a lot of speed for very low VRM usage")
parser.add_argument("--unload-gfpgan",action='store_true',help="does not do anything.")
parser.add_argument("--unload-gfpgan",action='store_true',help="does not do anything.")
parser.add_argument("--precision",type=str,help="evaluate at this precision",choices=["full","autocast"],default="autocast")
parser.add_argument("--precision",type=str,help="evaluate at this precision",choices=["full","autocast"],default="autocast")
parser.add_argument("--share",action='store_true',help="use share=True for gradio and make the UI accessible through their site (doesn't work for me but you might have better luck)")
parser.add_argument("--share",action='store_true',help="use share=True for gradio and make the UI accessible through their site (doesn't work for me but you might have better luck)")
parser.add_argument("--ngrok",type=str,help="ngrok authtoken, alternative to gradio --share",default=None)
parser.add_argument("--codeformer-models-path",type=str,help="Path to directory with codeformer model file(s).",default=os.path.join(models_path,'Codeformer'))
parser.add_argument("--codeformer-models-path",type=str,help="Path to directory with codeformer model file(s).",default=os.path.join(models_path,'Codeformer'))
parser.add_argument("--gfpgan-models-path",type=str,help="Path to directory with GFPGAN model file(s).",default=os.path.join(models_path,'GFPGAN'))
parser.add_argument("--gfpgan-models-path",type=str,help="Path to directory with GFPGAN model file(s).",default=os.path.join(models_path,'GFPGAN'))
parser.add_argument("--esrgan-models-path",type=str,help="Path to directory with ESRGAN model file(s).",default=os.path.join(models_path,'ESRGAN'))
parser.add_argument("--esrgan-models-path",type=str,help="Path to directory with ESRGAN model file(s).",default=os.path.join(models_path,'ESRGAN'))
@ -47,9 +50,10 @@ parser.add_argument("--ldsr-models-path", type=str, help="Path to directory with
parser.add_argument("--xformers",action='store_true',help="enable xformers for cross attention layers")
parser.add_argument("--xformers",action='store_true',help="enable xformers for cross attention layers")
parser.add_argument("--force-enable-xformers",action='store_true',help="enable xformers for cross attention layers regardless of whether the checking code thinks you can run it; do not make bug reports if this fails to work")
parser.add_argument("--force-enable-xformers",action='store_true',help="enable xformers for cross attention layers regardless of whether the checking code thinks you can run it; do not make bug reports if this fails to work")
parser.add_argument("--opt-split-attention",action='store_true',help="force-enables cross-attention layer optimization. By default, it's on for torch.cuda and off for other torch devices.")
parser.add_argument("--opt-split-attention",action='store_true',help="force-enables Doggettx's cross-attention layer optimization. By default, it's on for torch cuda.")
parser.add_argument("--opt-split-attention-invokeai",action='store_true',help="force-enables InvokeAI's cross-attention layer optimization. By default, it's on when cuda is unavailable.")
parser.add_argument("--opt-split-attention-v1",action='store_true',help="enable older version of split attention optimization that does not consume all the VRAM it can find")
parser.add_argument("--opt-split-attention-v1",action='store_true',help="enable older version of split attention optimization that does not consume all the VRAM it can find")
parser.add_argument("--use-cpu",nargs='+',choices=['SD','GFPGAN','BSRGAN','ESRGAN','SCUNet','CodeFormer'],help="use CPU as torch device for specified modules",default=[])
parser.add_argument("--use-cpu",nargs='+',choices=['SD','GFPGAN','BSRGAN','ESRGAN','SCUNet','CodeFormer'],help="use CPU as torch device for specified modules",default=[])
parser.add_argument("--listen",action='store_true',help="launch gradio with 0.0.0.0 as server name, allowing to respond to network requests")
parser.add_argument("--listen",action='store_true',help="launch gradio with 0.0.0.0 as server name, allowing to respond to network requests")
parser.add_argument("--port",type=int,help="launch gradio with given server port, you need root/admin rights for ports < 1024, defaults to 7860 if available",default=None)
parser.add_argument("--port",type=int,help="launch gradio with given server port, you need root/admin rights for ports < 1024, defaults to 7860 if available",default=None)
@ -66,6 +70,7 @@ parser.add_argument("--autolaunch", action='store_true', help="open the webui UR
parser.add_argument("--use-textbox-seed",action='store_true',help="use textbox for seeds in UI (no up/down, but possible to input long seeds)",default=False)
parser.add_argument("--use-textbox-seed",action='store_true',help="use textbox for seeds in UI (no up/down, but possible to input long seeds)",default=False)
parser.add_argument("--disable-console-progressbars",action='store_true',help="do not output progressbars to console",default=False)
parser.add_argument("--disable-console-progressbars",action='store_true',help="do not output progressbars to console",default=False)
parser.add_argument("--enable-console-prompts",action='store_true',help="print prompts to console when generating with txt2img and img2img",default=False)
parser.add_argument("--enable-console-prompts",action='store_true',help="print prompts to console when generating with txt2img and img2img",default=False)
parser.add_argument('--vae-path',type=str,help='Path to Variational Autoencoders model',default=None)
parser.add_argument("--disable-safe-unpickle",action='store_true',help="disable checking pytorch models for malicious code",default=False)
parser.add_argument("--disable-safe-unpickle",action='store_true',help="disable checking pytorch models for malicious code",default=False)
@ -81,10 +86,17 @@ parallel_processing_allowed = not cmd_opts.lowvram and not cmd_opts.medvram
"enable_emphasis":OptionInfo(True,"Emphasis: use (text) to make model pay more attention to text and [text] to make it pay less attention"),
"enable_emphasis":OptionInfo(True,"Emphasis: use (text) to make model pay more attention to text and [text] to make it pay less attention"),
"use_old_emphasis_implementation":OptionInfo(False,"Use old emphasis implementation. Can be useful to reproduce old seeds."),
"use_old_emphasis_implementation":OptionInfo(False,"Use old emphasis implementation. Can be useful to reproduce old seeds."),
"enable_batch_seeds":OptionInfo(True,"Make K-diffusion samplers produce same images in a batch as when making a single image"),
"enable_batch_seeds":OptionInfo(True,"Make K-diffusion samplers produce same images in a batch as when making a single image"),
"comma_padding_backtrack":OptionInfo(20,"Increase coherency by padding from the last comma within n tokens when using more than 75 tokens",gr.Slider,{"minimum":0,"maximum":74,"step":1}),
'CLIP_stop_at_last_layers':OptionInfo(1,"Stop At last layers of CLIP model",gr.Slider,{"minimum":1,"maximum":12,"step":1}),
'CLIP_stop_at_last_layers':OptionInfo(1,"Stop At last layers of CLIP model",gr.Slider,{"minimum":1,"maximum":12,"step":1}),
"random_artist_categories":OptionInfo([],"Allowed categories for random artists selection when using the Roll button",gr.CheckboxGroup,{"choices":artist_db.categories()}),
"random_artist_categories":OptionInfo([],"Allowed categories for random artists selection when using the Roll button",gr.CheckboxGroup,{"choices":artist_db.categories()}),