lllyasviel / lllyasviel/stable-diffusion-webui-forge
[Bug]: Send to IMG2IMG doesn't copy CFG
- Dominant language
- Python
- Stars
- 13k
- Forks
- 1.7k
- PR merge metrics
- No merged PRs in 30d
Description
### Checklist
- [X] The issue exists after disabling all extensions
- [ ] The issue exists on a clean installation of webui
- [ ] The issue is caused by an extension, but I believe it is caused by a bug in the webui
- [X] The issue exists in the current version of the webui
- [X] The issue has not been reported before recently
- [ ] The issue has been reported before but has not been fixed yet
### What happened?
When I generate in TEXT2IMG and send the output to IMG2IMG, the used CFG (but not STEPS!) changes to the default of 7.
### Steps to reproduce the problem
For example I do TEXT2IMG with 6 steps and 1.5 CFG, then I send it to IMG2IMG and the steps will be set to 6, but CFG will be set to 7 (=standard value).
### What should have happened?
After sending to IMG2IMG the CFG should be set to 1.5 there.
### What browsers do you use to access the UI ?
Mozilla Firefox
### Sysinfo
[sysinfo-2024-03-28-17-26.json](https://github.com/lllyasviel/stable-diffusion-webui-forge/files/14793444/sysinfo-2024-03-28-17-26.json)
### Console logs
```Shell
Python 3.10.6 (tags/v3.10.6:9c7b4bd, Aug 1 2022, 21:53:49) [MSC v.1932 64 bit (AMD64)]
Version: f0.0.17v1.8.0rc-latest-276-g29be1da7
Commit hash: 29be1da7cf2b5dccfc70fbdd33eb35c56a31ffb7
Launching Web UI with arguments:
Total VRAM 12288 MB, total RAM 32694 MB
Set vram state to: NORMAL_VRAM
Device: cuda:0 NVIDIA GeForce RTX 3060 : native
Hint: your device supports --pin-shared-memory for potential speed improvements.
Hint: your device supports --cuda-malloc for potential speed improvements.
Hint: your device supports --cuda-stream for potential speed improvements.
VAE dtype: torch.bfloat16
CUDA Stream Activated: False
Using pytorch cross attention
*** "Disable all extensions" option was set, will not load any extensions ***
Loading weights [fdbe56354b] from C:\programs\SD-Forge\webui\models\Stable-diffusion\Lightning\dreamshaperXL_lightningDPMSDE.safetensors
Running on local URL: http://127.0.0.1:7860
To create a public link, set `share=True` in `launch()`.
Startup time: 9.2s (prepare environment: 2.0s, import torch: 3.4s, import gradio: 0.9s, setup paths: 0.8s, initialize shared: 0.1s, other imports: 0.6s, load scripts: 0.6s, create ui: 0.3s, gradio launch: 0.5s).
model_type EPS
UNet ADM Dimension 2816
Using pytorch attention in VAE
Working with z of shape (1, 4, 32, 32) = 4096 dimensions.
Using pytorch attention in VAE
extra {'cond_stage_model.clip_g.transformer.text_model.embeddings.position_ids', 'cond_stage_model.clip_l.transformer.text_model.embeddings.position_ids', 'cond_stage_model.clip_l.logit_scale', 'cond_stage_model.clip_l.text_projection'}
left over keys: dict_keys(['conditioner.embedders.0.logit_scale', 'conditioner.embedders.0.text_projection'])
To load target model SDXLClipModel
Begin to load 1 model
[Memory Management] Current Free GPU Memory (MB) = 11246.857421875
[Memory Management] Model Memory (MB) = 2144.3546981811523
[Memory Management] Minimal Inference Memory (MB) = 1024.0
[Memory Management] Estimated Remaining GPU Memory (MB) = 8078.502723693848
Moving model(s) has taken 0.52 seconds
Model loaded in 5.6s (load weights from disk: 0.4s, forge instantiate config: 1.1s, forge load real models: 2.9s, load VAE: 0.4s, calculate empty prompt: 0.7s).
token_merging_ratio = 0.3
To load target model SDXL
Begin to load 1 model
[Memory Management] Current Free GPU Memory (MB) = 11210.64794921875
[Memory Management] Model Memory (MB) = 4897.086494445801
[Memory Management] Minimal Inference Memory (MB) = 1024.0
[Memory Management] Estimated Remaining GPU Memory (MB) = 5289.561454772949
Moving model(s) has taken 1.14 seconds
100%|████████████████████████████████████████████████████████████████████████████████████| 6/6 [00:07<00:00, 1.29s/it]
To load target model AutoencoderKL███████████████████████████████████████████████████████| 6/6 [00:06<00:00, 1.23s/it]
Begin to load 1 model
[Memory Management] Current Free GPU Memory (MB) = 6147.52197265625
[Memory Management] Model Memory (MB) = 159.55708122253418
[Memory Management] Minimal Inference Memory (MB) = 1024.0
[Memory Management] Estimated Remaining GPU Memory (MB) = 4963.964891433716
Moving model(s) has taken 0.14 seconds
Cleanup minimal inference memory.
Total progress: 100%|████████████████████████████████████████████████████████████████████| 6/6 [00:11<00:00, 1.84s/it]
Python 3.10.6 (tags/v3.10.6:9c7b4bd, Aug 1 2022, 21:53:49) [MSC v.1932 64 bit (AMD64)]██| 6/6 [00:11<00:00, 1.23s/it]
```
### Additional information
This is happening in AUTO1111 too, but this behaviour doesn't make sense to me.
Contributor guide
No contributing guide indexed for this repository
Research direction
Reproduce the issue by generating in TEXT2IMG with 6 steps and 1.5 CFG, then sending the result to IMG2IMG. Trace the parameter transfer between the two UI tabs; done means IMG2IMG retains the original CFG value while preserving the existing steps behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 35/100