Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

extra_only / main_ui_only ScriptPostprocessing #16374

Merged
merged 2 commits into from
Oct 29, 2024
Merged

Conversation

w-e-w
Copy link
Collaborator

@w-e-w w-e-w commented Aug 12, 2024

Description

fix Simple Upscale

mentioned by @light-and-ray in Discord for whatever reason the the main UI only script Simple Upscale was hidden and not selectable

my guess is doing some refactoring some logical change and so it got lost

this PR as it back by changing how a ScriptPostprocessingis filtered out by adding 2 new attribute toScriptPostprocessing, ScriptPostprocessing.extra_onlyandScriptPostprocessing.main_ui_onlywhen set toTure`, the script will only show ther specified tab

example
Simple Upscale now has the .main_ui_only set to true
and so will only work in main ui if added into opts.postprocessing_enable_in_main_ui

shared_items.postprocessing_scripts(filter_out_extra_only=False, filter_out_main_ui_only=False) now have filter options to filter out the two script types

the advantage of doing this way as opposed to adding a special case for Simple Upscale is that extensions if they so wish to can limit their use on specific tabs

Screenshots/videos:

image
image

Checklist:

@w-e-w w-e-w requested a review from AUTOMATIC1111 as a code owner August 12, 2024 22:00
@w-e-w w-e-w marked this pull request as draft August 12, 2024 22:04
add extra_only and main_ui_only attr to ScriptPostprocessing
a script with extra_only = True can only run on extra and not be used in main UI, vice versa
shared_items.postprocessing_scripts now have filter_out_main_ui_only and filter_out_extra_only args
@w-e-w w-e-w marked this pull request as ready for review August 12, 2024 22:53
@w-e-w w-e-w changed the title fix Simple Upscale extra_only / main_ui_only ScriptPostprocessing; fix Simple Upscale Aug 12, 2024
@catboxanon catboxanon changed the title extra_only / main_ui_only ScriptPostprocessing; fix Simple Upscale extra_only / main_ui_only ScriptPostprocessing Oct 29, 2024
@catboxanon catboxanon merged commit 0bf36cf into dev Oct 29, 2024
6 checks passed
@catboxanon catboxanon deleted the fix-Simple-Upscale branch October 29, 2024 14:35
bluelovers added a commit to bluelovers/stable-diffusion-webui that referenced this pull request Nov 26, 2024
* dev-a1111:
  fix passing of literal backslash (AUTOMATIC1111#16671)
  fix prompt-bracket-checker miscounting of literal tokens (AUTOMATIC1111#16669)
  Bump safetensors to v0.4.5
  Honor lossless webp compression option in API
  use shared.hf_endpoint (AUTOMATIC1111#16611)
  Warn if WebUI is installed under a dot directory (AUTOMATIC1111#16584)
  sd_xl_v.yaml: use_checkpoint = False
  XYZ option to disable grid (AUTOMATIC1111#16416)
  Fix Default system None filter logic (AUTOMATIC1111#16309)
  Fix weighting config for SDXL v-pred
  InputAccordion duplicate elem_id handling (AUTOMATIC1111#16381)
  addEventListener {passive: false} (AUTOMATIC1111#16575)
  pyenv-win compatibility - another approach (AUTOMATIC1111#16287)
  Disable Hires checkpoint if same as First pass checkpoint (AUTOMATIC1111#16269)
  Fix postprocessing_enable_in_main_ui ScriptPostprocessing elem_id (AUTOMATIC1111#16373)
  extra_only / main_ui_only ScriptPostprocessing (AUTOMATIC1111#16374)
  Allow newline in Extra Network activation text (AUTOMATIC1111#16428)
  image embedding data cache (AUTOMATIC1111#16556)
  Fix typo
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants