empty selection for *Hires VAE / TE* means 'use modules built-in to the model file', same as top-row VAE / TE selection. But this must be written to infotext as something, to distinguish from the non-HiRes case.
adds selection of none/same/different modules for hiresfix
('Use same choices' default option has priority over other selections made at same time.)
includes saving/loading from infotext
* prevent (Managed by Forge) settings reverting to default
* save CLIP skip to config when changed, inconsistent / unpredictable saving behaviour otherwise
- `/sdapi/v1/options` GET now calls `get_config()` from **sysinfo** module, instead of from its own version of the function.
- Defined a new, flexible and more robust `set_config()` function in **sysinfo** module, which:
- obsoletes redundant code
- skips updating values that are unchanged
- has flexible args for both API and UI use
- `/sdapi/v1/options` POST and `override_settings` now use the new `set_config()` function. `set_config()` could possibly obsolete additional functions, but I'm not going to get into that just yet.
- Options for `forge_additional_modules` can now be provided either as the file path, or just the module name.
- Most importantly, `refresh_model_loading_parameters()` is now only called ONCE per request, and **only** if necessary.
- It is now much easier to call `shared.opts.save()` as needed
* Do refresh load params for modules
* Adjust call order for model mgmt/prompt cache
* new function `manage_model_and_prompt_cache()` to improve code clarity
* make unload_model_weights do that
* rename Settings > Actions > unload checkpoint button to 'Unload all models'
* remove (comment out) reload button, as it does nothing and is unlikely to ever do anything since models are loaded on demand
(#1862)
a fix for the 0.01% who use comments in prompts. Before this, styles could be considered part of a comment.
strips comments from prompts first, then from each applied style before merge
same process for extracting styles from prompts
updated tooltips for toolbuttons to apply styles
removed code made redundant by this change, from modules.processing_scripts.comments
Allows setting of preferred VAE and Text encoder(s) for checkpoints when selected via Checkpoint cards. No selection saved means no change to current toprow setting. 'Built in' option, if the only choice, means clear the toprow selection (therefore use vae/te built-in to checkpoint).
Also allows setting model type for checkpoints (SD1/SD2/SDXL/Flux/Unknown) (user set only, no attempt at autodetection), enabling filtering of the cards based on UI preset.
adds options for user-set defaults for Sampler and Scheduler to UI settings sd, xl, flux;
adds options for user-set defaults for GPU Weights to UI settings xl, flux;
necessitates change to .input event listener instead of .release for ui_forge_inference_memory, which may be more correct anyway.
Added Flux to lora types in extra networks UI, so user can set.
Loras versioned first by user-set type, if any. Falls back to heuristics - these are much more reliable than the removed old A1111 tests and in case of no match default to Unknown (always displayed).
Filtering is done based on UI setting. 'all' setting does not filter. Filters lora lists on change.
Removed unused 'lora_hide_unknown_for_versions' setting.
Previously these were Numbers, and limited to integers, with no range check.
Some schedulers don't respect these values anyway, but that's a different issue.
* autoset width and height
When loading into img2img, added an option to autoset Width and Height from image (Settings -> img2img ->After loading into Img2img, automatically update Width and Height).
Also fixed scale_by display, now correctly rounded to multiple of 8
Also fixed img2img new width/height calculation, same way, (affects infotext)
* Update ui.py: hide progress animation on image size change
#1760, original solution by cmdr2. extended to 2 other locations where setting is read. I could replicate the issue only by manually entering a decimal value.
Possibly also #1764. Though I don't know how the clipskip setting became a string.
Re-enables *hires_fix_show_sampler* and *hires_fix_show_prompts* user-configurable settings.
Also corrects the reported result width x height; now rounded down to multiple of 8.
#1247
* fix GFPGAN to work with visibility < 1
* fix codeformer to work with visibility < 1
* try harder to download GFPGAN model. Old method would download only if there were no .pth models in the GFPGAN directory. If codeformer was used before GFPGAN, the supporting models are already downloaded into the GFPGAN directory.