Coder Social home page Coder Social logo

mcmonkeyprojects / swarmui Goto Github PK

View Code? Open in Web Editor NEW
1.0K 13.0 79.0 12.66 MB

SwarmUI (formerly StableSwarmUI), A Modular Stable Diffusion Web-User-Interface, with an emphasis on making powertools easily accessible, high performance, and extensibility.

License: MIT License

Dockerfile 0.02% Jupyter Notebook 0.13% Shell 0.34% Batchfile 0.18% PowerShell 0.04% Python 4.79% C# 51.43% CSS 4.64% JavaScript 32.91% HTML 5.51%
ai csharp image-generation javascript machine-learning ml python stable-diffusion comfyui

swarmui's Introduction

SwarmUI

SwarmUI v0.9.2 Beta.

Formerly known as StableSwarmUI.

A Modular Stable Diffusion Web-User-Interface, with an emphasis on making powertools easily accessible, high performance, and extensibility.

ui-screenshot

Join the Discord to discuss the project, get support, see announcements, etc.

Follow the Feature Announcements Thread for updates on new features.


Status

This project is in Beta status. This means for most tasks, Swarm has excellent tooling available to you, but there is much more planned. Swarm is recommended as an ideal UI for most users, beginners and pros alike. There are still some things to be worked out.

Beginner users will love Swarm's primary Generate tab interface, making it easy to generate anything with a variety of powerful features. Advanced users may favor the Comfy Workflow tab to get the unrestricted raw graph, but will still have reason to come back to the Generate tab for convenience features (image editor, auto-workflow-generation, etc) and powertools (eg Grid Generator).

Those interested in helping push Swarm from Beta to a Full ready-for-anything perfected Release status are welcome to submit PRs (read the Contributing document first), and you can contact us here on GitHub or on Discord. I highly recommend reaching out to ask about plans for a feature before PRing it. There may already be specific plans or even a work in progress.

Key feature targets not yet implemented:

  • Better mobile browser support
  • full detail "Current Model" display in UI, separate from the model selector (probably as a tab within the batch sidebar?)
    • And a way to dynamically shift tabs around between spots for convenience / layout customization
  • LLM-assisted prompting
  • convenient direct-distribution of Swarm as a program (Electron app?)

Try It On Google Colab or Runpod

Google Colab

WARNING: Google Colab does not necessarily allow remote WebUIs, particularly for free accounts, use at your own risk.

Colab link if you want to try Swarm: https://colab.research.google.com/github/mcmonkeyprojects/SwarmUI/blob/master/colab/colab-notebook.ipynb

Runpod

Runpod template (note: maintained by third party contributor nerdylive123): https://runpod.io/console/deploy?template=u7mlkrmxq3&ref=c6jd6jj0

Note it may take several minutes to start up the first time. Check the container logs to see setup progress. Check the template ? info for hints on how to use.

Installing on Windows

Note: if you're on Windows 10, you may need to manually install git and DotNET 8 SDK first. (Windows 11 this is automated).

  • Download The Install-Windows.bat file, store it somewhere you want to install at (not Program Files), and run it.
    • It should open a command prompt and install itself.
    • If it closes without going further, try running it again, it sometimes needs to run twice. (TODO: Fix that)
    • It will place an icon on your desktop that you can use to re-launch the server at any time.
    • When the installer completes, it will automatically launch the SwarmUI server, and open a browser window to the install page.
    • Follow the install instructions on the page.
    • After you submit, be patient, some of the install processing take a few minutes (downloading models and etc).

(TODO): Even easier self-contained pre-installer, a .msi or .exe that provides a general install screen and lets you pick folder and all.

Alternate Manual Windows Install

Installing on Linux

  • Install git, python3 via your OS package manager if they are not already installed (make sure to include pip and venv on distros that do not include them in python directly)

    • For example, on recent Ubuntu versions, sudo apt install git python3-pip python3-venv
  • Download the install-linux.sh file, store it somewhere you want to install at, and run it

    • If you like terminals, you can open a terminal to the folder and run the following commands:
      • wget https://github.com/mcmonkeyprojects/SwarmUI/releases/download/0.6.5-Beta/install-linux.sh -O install-linux.sh
      • chmod +x install-linux.sh
  • Run the ./install-linux.sh script, it will install everything for you and eventually open the webpage in your browser.

  • Follow the install instructions on-page.

  • You can at any time in the future run the launch-linux.sh script to re-launch Swarm.

  • If the page doesn't open itself, you can manually open http://localhost:7801

Alternate Manual Linux Install

  • Install git, python3 via your OS package manager if they are not already installed (make sure to include pip and venv on distros that do not include them in python directly)
    • For example, on recent Ubuntu versions, sudo apt install git python3-pip python3-venv
  • Install DotNET 8 using the instructions at https://dotnet.microsoft.com/en-us/download/dotnet/8.0 (you need dotnet-sdk-8.0, as that includes all relevant sub-packages)
    • Some users have said that certain Linux distros expect aspnet-runtime to be installed separately
  • Open a shell terminal and cd to a directory you want to install into
  • Run shell commands:
    • git clone https://github.com/mcmonkeyprojects/SwarmUI
    • cd SwarmUI
    • ./launch-linux.sh
  • open http://localhost:7801/Install (if it doesn't launch itself)
  • Follow the install instructions on-page.

(TODO): Maybe outlink a dedicated document with per-distro details and whatever. Maybe also make a one-click installer for Linux?

Installing on Mac

Note: You can only run SwarmUI on Mac computers with M1 or M2 (Mx) Apple silicon processors.

  • Open Terminal.
  • Ensure your brew packages are updated with brew update.
  • Verify your brew installation with brew doctor. You should not see any error in the command output.
  • Install .NET for macOS: brew install dotnet.
  • If you don't have Python, install it: brew install [email protected] and brew install virtualenv
  • Change the directory (cd) to the folder where you want to install SwarmUI.
  • Clone the SwarmUI GitHub repository: git clone https://github.com/mcmonkeyprojects/SwarmUI.
  • cd SwarmUI and run the installation script: ./launch-macos.sh.

The installation starts now and downloads the Stable Diffusion models from the internet. Depending on your internet connection, this may take several minutes. Wait for your web browser to open the SwarmUI window.

During the SwarmUI installation, you are prompted for the type of backend you want to use. For Mac computers with M1 or M2, you can safely choose the ComfyUI backend and choose the Stable Diffusion XL Base and Refiner models in the Download Models screen.

Running with Docker

  • To forward an Nvidia GPU, you must have the Nvidia Container Toolkit installed: https://docs.nvidia.com/datacenter/cloud-native/container-toolkit/latest/install-guide.html
  • Open a shell terminal and cd to a directory you want to install into
  • Run shell commands:
    • git clone https://github.com/mcmonkeyprojects/SwarmUI
    • cd SwarmUI
    • ./launch-docker.sh
    • Open your browser to localhost:7801
  • Note that it will forward the Models and Output directory, and will mount Data and dlbackend as independent persistent volumes.

Documentation

See the documentation folder.

Motivations

The "Swarm" name is in reference to the original key function of the UI: enabling a 'swarm' of GPUs to all generate images for the same user at once (especially for large grid generations). This is just the feature that inspired the name and not the end all of what Swarm is.

The overall goal of SwarmUI is to a be full-featured one-stop-shop for all things Stable Diffusion.

See the motivations document for motivations on technical choices.

Legal

This project:

SwarmUI itself is under the MIT license, however some usages may be affected by the GPL variant licenses of connected projects list above, and note that any models used have their own licenses.

Previous License

(For updates prior to June 2024)

The MIT License (MIT) Copyright (c) 2024 Stability AI

License

The MIT License (MIT)

Copyright (c) 2024 Alex "mcmonkey" Goodwin

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

swarmui's People

Contributors

ajantti avatar ashtakaoof avatar bash-j avatar binaryquantumsoul avatar camenduru avatar cholmesfr avatar crazeejeeves avatar dwedit avatar homuch avatar isiahw1 avatar jorge-campo avatar maedtb avatar mbuc avatar mcmonkey4eva avatar mfedosov avatar myshadowww avatar nerdylive123 avatar neverbiasu avatar nightgrey avatar olivierlacan avatar pythongosssss avatar rickles42 avatar sampletexting avatar surfingdoggo avatar wottso avatar xhoxye avatar yoinked-h avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

swarmui's Issues

A/B Slider in Preview Area

Might be useful to more effectively check effect of an effect like segmentation-refine, it would be great to get an A/B slider preview to see there generation with/without the effect

Include SUPIR in SwarmUI

SUPIR is the best upscaler but requieres a olot of VRAM, the option of include supir with optimization with an inpainting options, checkpoints and loras will be incredible

Thanks

Option to store Comfy Workflows in Swarm images

Hey there,

I built a workflow that ended with SwarmSaveImageWS, and then clicked the "Use this workflow in the Generate Tab" to have a nicer UI to batch images. Then, I wanted to inpaint parts of the original image generated by the workflow, so I clicked the button saying "remove workflow" to get back to the regular interface so I use img2img. However, I then wanted to tweak the workflow I used to create the OG image in the first place, but the built-in ComfyUI does not load it. I looked in the PNG metadata and the embed workflow, which ComfyUI uses, is gone, so I had to recreate the entire workflow from scratch.

I'm not sure if this is intended behavior, but it certainly should be, or at least an option in the settings.

Thanks for the great software!

[GridGen] button to quickly toggle or remove values

Would be great to apply the same feature of token one-click remove in the grid generator like it is possible to do with lora's for instance

image

Often find myself editing which sampler or Lora to remove from a long list. Having to highlight and delete, and delete the comma exacerbates the amount of clicks required to setup a grid.

Anyway, maybe not a priority but a happy quality of life improvement

image

Allow Model Downloader to parse URLs where only a single model version exists

Feature Idea

I download new models frequently and one I tried in Utilities -> Model Downloader is: epiCRainbowDash

Swarm returns the message:

Status: URL appears to be a CivitAI link, but not a specific model. Please use the path of a specific model.

I cannot find a link to the specific model so I'm unable to download through Swarm and had to do it manually.

Then in Edit Model Metadata, I entered the URL but it refused to link and pull any metadata. So now this model sits there in the list with the default thumbnail and no info.

I don't know if this should be a feature request or a bug report because Model Downloader expects a link to a file, not a page. However, the model definitely exists at that URL but Model Downloader can't see it.

I'm guessing it's down to there being only one model version available. Any time there are v1.0, v2.0, etc. there is no problem as clicking on each version number returns a URL specific to that version, therefore allowing Model Downloader to see it and proceed.

So I'm filing this as a feature request, asking that Model Downloader be able to parse URLs where only a single model version exists.

Other

No response

Pen Pressure in Image editor: Snaps and lags in straight liness

Expected Behavior

Run smoothly when adjusting pen pressure

Actual Behavior

starts off smooth, but then gets choppy and only draws in straight lines and lagging

Steps to Reproduce

drawing tablet, stylus and drawing on the image editor

Debug Logs

nothing to do with logs

Other

Just a quick comparison between Photopea, The painter node and Swarm Image editor to show what I mean, I do not think this is a graphics tablet issue, maybe?

Photopea.vs.Painter.node.vs.swarm.Image.editor.mp4

Seamless Tiling doesn't work with SD3

Expected Behavior

When "Seamless tileable" option in "Sampling" is set to "true", SD3 (like any other model) supposed to generate images that can be stacked together with no identifiable seams. It works perfectly with SDXL and earlier SD versions.

SDXL image
image

Actual Behavior

Regardless of prompt details, sampler methods, and most importantly, activation of "Seamless Tileable" tooggle, the resulting image is not a seamless tileable pattern, as seen below.

SD3 image (all the same parameters otherwise)
image

Steps to Reproduce

  • Model: sd3_medium_incl_clips_t5xxlfp8
  • Resolution: 1024 x 1024
  • Prompt example: seamless pattern, large autumn leaves, minimal
  • Any sampler method, CFG and number of steps

Debug Logs

There are no errors, all seems normal.

Other

No response

CivitAI downloader - Handling filenames with slash symbol on Windows.

I tried to download this Lora (warning: NSFW images): https://civitai.com/models/287657/oroborus-savagexthicc-style-lora
Got an error: "Error: Failed to download the model due to internal exception. "
In the console window, there is exception:

Failed to download the model due to internal exception: System.IO.DirectoryNotFoundException: Could not find a part of the path 'D:\sd_models\Lora\Oroborus\Savagexthicc - Style LoRA - Oroborus PonyXL.download.tmp'.
   at Microsoft.Win32.SafeHandles.SafeFileHandle.CreateFile(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options)

So, basicaly, instead of full filename, Windows interpreted it like a local path.

Mask Inversion

It would be great if it were possible to quickly and easily invert a mask in img2img.
Either in the image editor to be able to right click and invert the mask, or on prompt level which causes an inversion node to be added.

SD3 use VAE error

Expected Behavior

sd3 normal use.

Actual Behavior

Invalid operation: ComfyUI execution error: Given groups=1, weight of size [1536, 16, 2, 2], expected input[1, 4, 128, 128] to have 16 channels, but got 4 channels instead

Steps to Reproduce

use sdxl-vae, sd-vae-ft-mse, sd-vae-ft-ema

Debug Logs

15:47:11.504 [Warning] WARNING: Model Stable Diffusion 3 - Medium is an SD3 model, but you have VAE sd-vae-ft-ema selected. If that VAE is not an SD3 specific VAE, this is likely a mistake. Errors may follow. If this breaks, disable the custom VAE.
15:47:18.686 [Warning] ComfyUI-0 on port 7821 stderr: Traceback (most recent call last):
15:47:18.687 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\ComfyUI\execution.py", line 151, in recursive_execute
15:47:18.688 [Warning] ComfyUI-0 on port 7821 stderr:     output_data, output_ui = get_output_data(obj, input_data_all)
15:47:18.689 [Warning] ComfyUI-0 on port 7821 stderr:                              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:18.690 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\ComfyUI\execution.py", line 81, in get_output_data
15:47:18.691 [Warning] ComfyUI-0 on port 7821 stderr:     return_values = map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True)
15:47:18.694 [Warning] ComfyUI-0 on port 7821 stderr:                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:18.695 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\ComfyUI\execution.py", line 74, in map_node_over_list
15:47:18.695 [Warning] ComfyUI-0 on port 7821 stderr:     results.append(getattr(obj, func)(**slice_dict(input_data_all, i)))
15:47:18.696 [Warning] ComfyUI-0 on port 7821 stderr:                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:18.697 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\src\BuiltinExtensions\ComfyUIBackend\ExtraNodes\SwarmComfyCommon\SwarmKSampler.py", line 298, in run_sampling
15:47:18.697 [Warning] ComfyUI-0 on port 7821 stderr:     return self.sample(model, noise_seed, steps, cfg, sampler_name, scheduler, positive, negative, latent_image, start_at_step, end_at_step, var_seed, var_seed_strength, sigma_max, sigma_min, rho, add_noise, return_with_leftover_noise, previews)
15:47:18.698 [Warning] ComfyUI-0 on port 7821 stderr:            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:18.699 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\src\BuiltinExtensions\ComfyUIBackend\ExtraNodes\SwarmComfyCommon\SwarmKSampler.py", line 271, in sample
15:47:18.700 [Warning] ComfyUI-0 on port 7821 stderr:     samples = comfy.sample.sample(model, noise, steps, cfg, sampler_name, scheduler, positive, negative, latent_samples,
15:47:18.701 [Warning] ComfyUI-0 on port 7821 stderr:               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:18.701 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\ComfyUI\comfy\sample.py", line 43, in sample
15:47:18.702 [Warning] ComfyUI-0 on port 7821 stderr:     samples = sampler.sample(noise, positive, negative, cfg=cfg, latent_image=latent_image, start_step=start_step, last_step=last_step, force_full_denoise=force_full_denoise, denoise_mask=noise_mask, sigmas=sigmas, callback=callback, disable_pbar=disable_pbar, seed=seed)
15:47:18.703 [Warning] ComfyUI-0 on port 7821 stderr:               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:18.704 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\ComfyUI\comfy\samplers.py", line 795, in sample
15:47:18.718 [Warning] ComfyUI-0 on port 7821 stderr:     return sample(self.model, noise, positive, negative, cfg, self.device, sampler, sigmas, self.model_options, latent_image=latent_image, denoise_mask=denoise_mask, callback=callback, disable_pbar=disable_pbar, seed=seed)
15:47:18.719 [Warning] ComfyUI-0 on port 7821 stderr:            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:18.721 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\ComfyUI\comfy\samplers.py", line 697, in sample
15:47:18.722 [Warning] ComfyUI-0 on port 7821 stderr:     return cfg_guider.sample(noise, latent_image, sampler, sigmas, denoise_mask, callback, disable_pbar, seed)
15:47:18.723 [Warning] ComfyUI-0 on port 7821 stderr:            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:18.723 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\ComfyUI\comfy\samplers.py", line 684, in sample
15:47:18.724 [Warning] ComfyUI-0 on port 7821 stderr:     output = self.inner_sample(noise, latent_image, device, sampler, sigmas, denoise_mask, callback, disable_pbar, seed)
15:47:18.725 [Warning] ComfyUI-0 on port 7821 stderr:              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:18.741 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\ComfyUI\comfy\samplers.py", line 663, in inner_sample
15:47:18.757 [Warning] ComfyUI-0 on port 7821 stderr:     samples = sampler.sample(self, sigmas, extra_args, callback, noise, latent_image, denoise_mask, disable_pbar)
15:47:18.774 [Warning] ComfyUI-0 on port 7821 stderr:               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:18.775 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\ComfyUI\comfy\samplers.py", line 568, in sample
15:47:18.776 [Warning] ComfyUI-0 on port 7821 stderr:     samples = self.sampler_function(model_k, noise, sigmas, extra_args=extra_args, callback=k_callback, disable=disable_pbar, **self.extra_options)
15:47:18.792 [Warning] ComfyUI-0 on port 7821 stderr:               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:18.803 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\python_embeded\Lib\site-packages\torch\utils\_contextlib.py", line 115, in decorate_context
15:47:18.804 [Warning] ComfyUI-0 on port 7821 stderr:     return func(*args, **kwargs)
15:47:18.805 [Warning] ComfyUI-0 on port 7821 stderr:            ^^^^^^^^^^^^^^^^^^^^^
15:47:18.805 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\ComfyUI\comfy\k_diffusion\sampling.py", line 599, in sample_dpmpp_2m
15:47:18.806 [Warning] ComfyUI-0 on port 7821 stderr:     denoised = model(x, sigmas[i] * s_in, **extra_args)
15:47:18.807 [Warning] ComfyUI-0 on port 7821 stderr:                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:18.807 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\ComfyUI\comfy\samplers.py", line 291, in __call__
15:47:18.808 [Warning] ComfyUI-0 on port 7821 stderr:     out = self.inner_model(x, sigma, model_options=model_options, seed=seed)
15:47:18.809 [Warning] ComfyUI-0 on port 7821 stderr:           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:18.835 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\ComfyUI\comfy\samplers.py", line 650, in __call__
15:47:18.837 [Warning] ComfyUI-0 on port 7821 stderr:     return self.predict_noise(*args, **kwargs)
15:47:18.839 [Warning] ComfyUI-0 on port 7821 stderr:            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:18.840 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\ComfyUI\comfy\samplers.py", line 653, in predict_noise
15:47:18.841 [Warning] ComfyUI-0 on port 7821 stderr:     return sampling_function(self.inner_model, x, timestep, self.conds.get("negative", None), self.conds.get("positive", None), self.cfg, model_options=model_options, seed=seed)
15:47:18.842 [Warning] ComfyUI-0 on port 7821 stderr:            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:18.854 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\ComfyUI\comfy\samplers.py", line 277, in sampling_function
15:47:18.869 [Warning] ComfyUI-0 on port 7821 stderr:     out = calc_cond_batch(model, conds, x, timestep, model_options)
15:47:18.872 [Warning] ComfyUI-0 on port 7821 stderr:           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:18.873 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\ComfyUI\comfy\samplers.py", line 226, in calc_cond_batch
15:47:18.874 [Warning] ComfyUI-0 on port 7821 stderr:     output = model.apply_model(input_x, timestep_, **c).chunk(batch_chunks)
15:47:18.875 [Warning] ComfyUI-0 on port 7821 stderr:              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:18.875 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\ComfyUI\comfy\model_base.py", line 113, in apply_model
15:47:18.902 [Warning] ComfyUI-0 on port 7821 stderr:     model_output = self.diffusion_model(xc, t, context=context, control=control, transformer_options=transformer_options, **extra_conds).float()
15:47:18.903 [Warning] ComfyUI-0 on port 7821 stderr:                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:18.906 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1532, in _wrapped_call_impl
15:47:18.906 [Warning] ComfyUI-0 on port 7821 stderr:     return self._call_impl(*args, **kwargs)
15:47:18.907 [Warning] ComfyUI-0 on port 7821 stderr:            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:18.908 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1541, in _call_impl
15:47:18.909 [Warning] ComfyUI-0 on port 7821 stderr:     return forward_call(*args, **kwargs)
15:47:18.910 [Warning] ComfyUI-0 on port 7821 stderr:            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:18.910 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\ComfyUI\comfy\ldm\modules\diffusionmodules\mmdit.py", line 961, in forward
15:47:18.935 [Warning] ComfyUI-0 on port 7821 stderr:     return super().forward(x, timesteps, context=context, y=y)
15:47:18.936 [Warning] ComfyUI-0 on port 7821 stderr:            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:18.939 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\ComfyUI\comfy\ldm\modules\diffusionmodules\mmdit.py", line 937, in forward
15:47:18.940 [Warning] ComfyUI-0 on port 7821 stderr:     x = self.x_embedder(x) + self.cropped_pos_embed(hw, device=x.device).to(dtype=x.dtype, device=x.device)
15:47:18.941 [Warning] ComfyUI-0 on port 7821 stderr:         ^^^^^^^^^^^^^^^^^^
15:47:18.942 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1532, in _wrapped_call_impl
15:47:18.972 [Warning] ComfyUI-0 on port 7821 stderr:     return self._call_impl(*args, **kwargs)
15:47:18.973 [Warning] ComfyUI-0 on port 7821 stderr:            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:18.974 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1541, in _call_impl
15:47:18.975 [Warning] ComfyUI-0 on port 7821 stderr:     return forward_call(*args, **kwargs)
15:47:18.975 [Warning] ComfyUI-0 on port 7821 stderr:            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:18.989 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\ComfyUI\comfy\ldm\modules\diffusionmodules\mmdit.py", line 113, in forward
15:47:18.990 [Warning] ComfyUI-0 on port 7821 stderr:     x = self.proj(x)
15:47:18.991 [Warning] ComfyUI-0 on port 7821 stderr:         ^^^^^^^^^^^^
15:47:18.992 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1532, in _wrapped_call_impl
15:47:19.002 [Warning] ComfyUI-0 on port 7821 stderr:     return self._call_impl(*args, **kwargs)
15:47:19.003 [Warning] ComfyUI-0 on port 7821 stderr:            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:19.011 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\python_embeded\Lib\site-packages\torch\nn\modules\module.py", line 1541, in _call_impl
15:47:19.014 [Warning] ComfyUI-0 on port 7821 stderr:     return forward_call(*args, **kwargs)
15:47:19.015 [Warning] ComfyUI-0 on port 7821 stderr:            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:19.016 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\ComfyUI\comfy\ops.py", line 80, in forward
15:47:19.017 [Warning] ComfyUI-0 on port 7821 stderr:     return super().forward(*args, **kwargs)
15:47:19.017 [Warning] ComfyUI-0 on port 7821 stderr:            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:19.018 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\python_embeded\Lib\site-packages\torch\nn\modules\conv.py", line 460, in forward
15:47:19.019 [Warning] ComfyUI-0 on port 7821 stderr:     return self._conv_forward(input, self.weight, self.bias)
15:47:19.019 [Warning] ComfyUI-0 on port 7821 stderr:            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:19.020 [Warning] ComfyUI-0 on port 7821 stderr:   File "D:\hzh\StableSwarmUI\dlbackend\comfy\python_embeded\Lib\site-packages\torch\nn\modules\conv.py", line 456, in _conv_forward
15:47:19.021 [Warning] ComfyUI-0 on port 7821 stderr:     return F.conv2d(input, weight, bias, self.stride,
15:47:19.022 [Warning] ComfyUI-0 on port 7821 stderr:            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:47:19.022 [Warning] ComfyUI-0 on port 7821 stderr: RuntimeError: Given groups=1, weight of size [1536, 16, 2, 2], expected input[1, 4, 128, 128] to have 16 channels, but got 4 channels instead
15:47:19.023 [Warning] ComfyUI-0 on port 7821 stderr:

Other

No response

Editing model metadata rewrites the whole file

Expected Behavior

When editing model metadata, the edit should save instantly with the minimum of disk writes.

Actual Behavior

The whole file is duplicated as it's rewritten, resulting in heavy disk writes.

Steps to Reproduce

While I was testing for this, I noticed another peculiarity:

While going through that process to edit metadata, the whole of the file is duplicated. It's not easy to spot with a small file - you need a checkpoint.

Again, open a file manager to observe the process. Pick a large checkpoint, refreshing the file manager directly after editing and saving the metadata. There will be an extra file:

ModelName.safetensors.tmp

When I watch my stats, I can see the disk activity clearly:

rewriting-whole-file

This is a problem if the model is stored on an HDD as it will be slow, potentially bogging down the system. If the model is on an SSD, it will cause unnecessary writes, shortening the lifespan of the SSD.

So I wonder: Why not just write the metadata to the .json file and leave the .safetensors file alone to avoid this situation altogether?

Debug Logs

Not relevant

Other

No response

Request to add "SKIP" button next to "GENERATE" button

I'm requesting a "SKIP" buttong to skip[ past a current generation in progress. So if your generating an image (like a batch of 4 or more) and one is looking pretty freaky you hit the "skip" button and it cancels out the generation and moves to the next..

Here is an example from Fooocus.

image

Android Termux Permission denied error

I got past the dot net stuff. Now I'm getting permission denied error any way to fix this on linux? Please respond asap. I hope this works:)

Unhandled exception. System.Net.NetworkInformation.NetworkInformationException (13): An error was encountered while querying information from the operating system. ---> System.UnauthorizedAccessException: Access to the path '/proc/net/tcp' is denied.
---> System.IO.IOException: Permission denied
--- End of inner exception stack trace ---
at Interop.ThrowExceptionForIoErrno(ErrorInfo errorInfo, String path, Boolean isDirError)
at Microsoft.Win32.SafeHandles.SafeFileHandle.Open(String path, OpenFlags flags, Int32 mode, Boolean failForSymlink, Boolean& wasSymlink, Func4 createOpenException) at Microsoft.Win32.SafeHandles.SafeFileHandle.Open(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize, UnixFileMode openPermissions, Int64& fileLength, UnixFileMode& filePermissions, Boolean failForSymlink, Boolean& wasSymlink, Func4 createOpenException)
at System.IO.Strategies.OSFileStreamStrategy..ctor(String path, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize, Nullable`1 unixCreateMode)
at System.IO.StreamReader.ValidateArgsAndOpenPath(String path, Encoding encoding, Int32 bufferSize)
at System.IO.File.ReadAllText(String path, Encoding encoding)
at System.Net.NetworkInformation.StringParsingHelpers.ReadAllText(String filePath)
at System.Net.NetworkInformation.StringParsingHelpers.ReadAllText(String filePath)
at System.Net.NetworkInformation.StringParsingHelpers.ParseActiveTcpListenersFromFiles(String tcp4ConnectionsFile, String tcp6ConnectionsFile)
at SwarmUI.Utils.Utilities.IsPortTaken(Int32 port) in /root/SwarmUI/src/Utils/Utilities.cs:line 480
at SwarmUI.Core.Program.ApplyCommandLineSettings() in /root/SwarmUI/src/Core/Program.cs:line 506
at SwarmUI.Core.Program.Main(String[] args) in /root/SwarmUI/src/Core/Program.cs:line 123
./launch-linux.sh: line 47: 1173 Aborted dotnet src/bin/live_release/SwarmUI.dll $@

Convert from Mask Layer to Image Layer and back

When drag and dropping a file into the image editor, it is automatically added as an image layer with no way to convert it to a mask layer. In case of having a previously exported mask image it makes it impossible to use via image editor later on.

Feature Request: Progress bar/% amount in tab window

After using auto1111 I swapped to Swarm cause it let me use my GPU for dat speedy iterations.

but when I was using Auto1111 I had a little XX% in the page name, this meant I could have a different tab open and it would tell me how far through the image gen it was.

Similarly an adjacent feature would be some kind of progress bar or estimate in the actual UI, so I can have some idea of when to check back in.

"Init Image Reset to Norm" encode full image resolution when do "Mask Shrink Grow"

Expected Behavior

When using the "Init Image Reset to Norm" slider with the "Mask Shrink Grow" option, it is expected to work only at resolutions of 512x512 or 1024x1024, depending on the selected model.

Actual Behavior

It performs an encode on the entire image. This is an issue for systems with low VRAM and high-resolution images.

Steps to Reproduce

Edit an image ---> create a mask ---> select the "Mask Shrink Grow" option ---> enter a value greater than 0 on the "Init Image Reset to Norm" slider

Debug Logs

2024-07-11 17:01:24.410 [Init] === SwarmUI v0.9.1.1 Starting at 2024-07-11 17:01:24 ===
2024-07-11 17:01:24.447 [Init] Prepping extension: SwarmUI.Builtin_ScorersExtension.ScorersExtension...
2024-07-11 17:01:24.455 [Init] Prepping extension: SwarmUI.Builtin_ImageBatchToolExtension.ImageBatchToolExtension...
2024-07-11 17:01:24.456 [Init] Prepping extension: SwarmUI.Builtin_GridGeneratorExtension.GridGeneratorExtension...
2024-07-11 17:01:24.456 [Init] Prepping extension: SwarmUI.Builtin_DynamicThresholding.DynamicThresholdingExtension...
2024-07-11 17:01:24.456 [Init] Prepping extension: SwarmUI.Builtin_ComfyUIBackend.ComfyUIBackendExtension...
2024-07-11 17:01:24.456 [Init] Prepping extension: SwarmUI.Builtin_AutoWebUIExtension.AutoWebUIBackendExtension...
2024-07-11 17:01:24.492 [Init] Parsing command line...
2024-07-11 17:01:24.492 [Init] Loading settings file...
2024-07-11 17:01:24.515 [Init] Re-saving settings file...
2024-07-11 17:01:24.534 [Init] Applying command line settings...
2024-07-11 17:01:24.560 [Init] Prepping options...
2024-07-11 17:01:24.727 [Init] Loading models list...
2024-07-11 17:01:24.762 [Init] Loading backends...
2024-07-11 17:01:24.763 [Init] Loading backends from file...
2024-07-11 17:01:24.766 [Init] Prepping API...
2024-07-11 17:01:24.767 [Init] Initializing backend #0 - ComfyUI Self-Starting...
2024-07-11 17:01:24.767 [Init] Backend request handler loop ready...
2024-07-11 17:01:24.769 [Init] Prepping webserver...
2024-07-11 17:01:24.923 [Init] Scan for web extensions...
2024-07-11 17:01:24.927 [Init] Readying extensions for launch...
2024-07-11 17:01:24.927 [Init] Launching server...
2024-07-11 17:01:24.927 [Init] Starting webserver on http://localhost:7801
2024-07-11 17:01:25.260 [Init] CPU Cores: 12 | RAM: 19.86 GiB total, 12.40 GiB available
2024-07-11 17:01:25.260 [Init] GPU 0: NVIDIA GeForce RTX 3050 Laptop GPU | Temp 47C | Util 0% GPU, 0% Memory | VRAM 4.00 GiB total, 3.87 GiB free, 0 B used
2024-07-11 17:01:25.943 [Init] Current git commit marked as date 2024-07-11 14:49:57
2024-07-11 17:01:25.973 [Init] Swarm is up to date! You have version 0.9.1.1, and 0.9.1-Beta is the latest.
2024-07-11 17:01:25.973 [Init] Program is running.
2024-07-11 17:01:26.478 [Init] Launch web browser to install page...
2024-07-11 17:01:26.854 [Info] Creating new admin session 'local' for ::1
2024-07-11 17:01:30.635 [Init] Self-Start ComfyUI-0 on port 7821 is loading...
2024-07-11 17:01:43.932 [Init] Self-Start ComfyUI-0 on port 7821 started.
2024-07-11 17:01:24.545 [Debug] [Load Time] Initial settings load took 0.13s (0.13s from start)
2024-07-11 17:01:24.560 [Debug] [Load Time] Extension PreInit took 0.02s (0.14s from start)
2024-07-11 17:01:24.675 [Debug] [Load Time] Prep Objects took 0.13s (0.27s from start)
2024-07-11 17:01:24.675 [Debug] [Load Time] Web PreInit took 0s (0.27s from start)
2024-07-11 17:01:24.682 [Debug] [Load Time] Extensions Init took 0s (0.27s from start)
2024-07-11 17:01:24.682 [Debug] [Load Time] Prep Utils took 0s (0.27s from start)
2024-07-11 17:01:24.727 [Debug] [Load Time] Languages load took 0.05s (0.31s from start)
2024-07-11 17:01:24.762 [Debug] [Load Time] Model listing took 0.03s (0.34s from start)
2024-07-11 17:01:24.766 [Debug] [Load Time] Backends took 0.02s (0.36s from start)
2024-07-11 17:01:24.769 [Debug] [Load Time] API took 0s (0.36s from start)
2024-07-11 17:01:24.810 [Debug] [Load Time] [Web] WebApp builder prep took 0.03s (0.03s from start)
2024-07-11 17:01:24.862 [Debug] [Load Time] [Web] WebApp build took 0.06s (0.09s from start)
2024-07-11 17:01:24.862 [Debug] [Load Time] [Web] exception handler took 0s (0.09s from start)
2024-07-11 17:01:24.862 [Debug] [Load Time] [Web] StartStop handler took 0s (0.09s from start)
2024-07-11 17:01:24.862 [Debug] [Load Time] [Web] static files took 0s (0.09s from start)
2024-07-11 17:01:24.921 [Debug] [Load Time] [Web] core use calls took 0.06s (0.16s from start)
2024-07-11 17:01:24.923 [Debug] [Load Time] [Web] core maps took 0s (0.16s from start)
2024-07-11 17:01:24.927 [Debug] [Load Time] [Web] end took 0s (0.16s from start)
2024-07-11 17:01:24.927 [Debug] [Load Time] Web prep took 0.16s (0.52s from start)
2024-07-11 17:01:24.927 [Debug] [Load Time] Extensions pre-launch took 0s (0.52s from start)
2024-07-11 17:01:24.969 [Debug] [Load Time] Web launch took 0.05s (0.56s from start)
2024-07-11 17:01:25.943 [Debug] Comfy node pull response for ComfyUI-SAI_API: Already up to date.
2024-07-11 17:01:25.943 [Debug] Comfy node pull response for sd-dynamic-thresholding: Already up to date.
2024-07-11 17:01:26.825 [Debug] Comfy node pull response for ComfyUI-SAI_API: Already up to date.
2024-07-11 17:01:28.604 [Debug] Comfy node pull response for comfyui_controlnet_aux: Already up to date.
2024-07-11 17:01:29.472 [Debug] Comfy node pull response for ComfyUI_IPAdapter_plus: Already up to date.
2024-07-11 17:01:30.625 [Debug] Comfy node pull response for sd-dynamic-thresholding: Already up to date.
2024-07-11 17:01:30.628 [Debug] Requested generic launch of ../ComfyUI/main.py on GPU 0 from ComfyUI-0
2024-07-11 17:01:30.630 [Debug] (ComfyUI-0 launch) Adding path C:\StabilityMatrix\Data\Packages\ComfyUI\venv
2024-07-11 17:01:30.630 [Debug] (ComfyUI-0 launch) Will use python: C:\StabilityMatrix\Data\Packages\ComfyUI\venv\Scripts\python.exe
2024-07-11 17:01:30.899 [Debug] [ComfyUI-0/STDOUT] [START] Security scan
2024-07-11 17:01:31.699 [Debug] [ComfyUI-0/STDOUT] [DONE] Security scan
2024-07-11 17:01:31.849 [Debug] [ComfyUI-0/STDOUT] ## ComfyUI-Manager: installing dependencies done.
2024-07-11 17:01:31.849 [Debug] [ComfyUI-0/STDOUT] ** ComfyUI startup time: 2024-07-11 17:01:31.848564
2024-07-11 17:01:31.849 [Debug] [ComfyUI-0/STDOUT] ** Platform: Windows
2024-07-11 17:01:31.849 [Debug] [ComfyUI-0/STDOUT] ** Python version: 3.10.11 (tags/v3.10.11:7d4cc5a, Apr  5 2023, 00:38:17) [MSC v.1929 64 bit (AMD64)]
2024-07-11 17:01:31.849 [Debug] [ComfyUI-0/STDOUT] ** Python executable: C:\StabilityMatrix\Data\Packages\ComfyUI\venv\Scripts\python.exe
2024-07-11 17:01:31.849 [Debug] [ComfyUI-0/STDOUT] ** ComfyUI Path: C:\StabilityMatrix\Data\Packages\ComfyUI
2024-07-11 17:01:31.849 [Debug] [ComfyUI-0/STDOUT] ** Log path: C:\StabilityMatrix\Data\Packages\ComfyUI\comfyui.log
2024-07-11 17:01:31.859 [Debug] [ComfyUI-0/STDOUT] 
2024-07-11 17:01:31.859 [Debug] [ComfyUI-0/STDOUT] Prestartup times for custom nodes:
2024-07-11 17:01:31.859 [Debug] [ComfyUI-0/STDOUT]    1.0 seconds: C:\StabilityMatrix\Data\Packages\ComfyUI\custom_nodes\ComfyUI-Manager
2024-07-11 17:01:31.859 [Debug] [ComfyUI-0/STDOUT] 
2024-07-11 17:01:35.414 [Debug] [ComfyUI-0/STDOUT] Total VRAM 4096 MB, total RAM 20332 MB
2024-07-11 17:01:35.415 [Debug] [ComfyUI-0/STDOUT] pytorch version: 2.1.2+cu121
2024-07-11 17:01:35.415 [Debug] [ComfyUI-0/STDOUT] Set vram state to: NORMAL_VRAM
2024-07-11 17:01:35.415 [Debug] [ComfyUI-0/STDOUT] Device: cuda:0 NVIDIA GeForce RTX 3050 Laptop GPU : cudaMallocAsync
2024-07-11 17:01:36.534 [Debug] [ComfyUI-0/STDOUT] Using pytorch cross attention
2024-07-11 17:01:37.345 [Debug] [ComfyUI-0/STDOUT] Adding extra search path checkpoints C:\StabilityMatrix\Data\Models\StableDiffusion
2024-07-11 17:01:37.345 [Debug] [ComfyUI-0/STDOUT] Adding extra search path vae C:\StabilityMatrix\Data\Models\VAE
2024-07-11 17:01:37.345 [Debug] [ComfyUI-0/STDOUT] Adding extra search path loras C:\StabilityMatrix\Data\Models\Lora
2024-07-11 17:01:37.346 [Debug] [ComfyUI-0/STDOUT] Adding extra search path loras C:\StabilityMatrix\Data\Models\LyCORIS
2024-07-11 17:01:37.346 [Debug] [ComfyUI-0/STDOUT] Adding extra search path upscale_models C:\StabilityMatrix\Data\Models\ESRGAN
2024-07-11 17:01:37.346 [Debug] [ComfyUI-0/STDOUT] Adding extra search path upscale_models C:\StabilityMatrix\Data\Models\RealESRGAN
2024-07-11 17:01:37.346 [Debug] [ComfyUI-0/STDOUT] Adding extra search path upscale_models C:\StabilityMatrix\Data\Models\SwinIR
2024-07-11 17:01:37.346 [Debug] [ComfyUI-0/STDOUT] Adding extra search path embeddings C:\StabilityMatrix\Data\Models\TextualInversion
2024-07-11 17:01:37.346 [Debug] [ComfyUI-0/STDOUT] Adding extra search path hypernetworks C:\StabilityMatrix\Data\Models\Hypernetwork
2024-07-11 17:01:37.346 [Debug] [ComfyUI-0/STDOUT] Adding extra search path controlnet C:\StabilityMatrix\Data\Models\ControlNet
2024-07-11 17:01:37.346 [Debug] [ComfyUI-0/STDOUT] Adding extra search path controlnet C:\StabilityMatrix\Data\Models\T2IAdapter
2024-07-11 17:01:37.346 [Debug] [ComfyUI-0/STDOUT] Adding extra search path clip C:\StabilityMatrix\Data\Models\CLIP
2024-07-11 17:01:37.346 [Debug] [ComfyUI-0/STDOUT] Adding extra search path clip_vision C:\StabilityMatrix\Data\Models\InvokeClipVision
2024-07-11 17:01:37.346 [Debug] [ComfyUI-0/STDOUT] Adding extra search path diffusers C:\StabilityMatrix\Data\Models\Diffusers
2024-07-11 17:01:37.346 [Debug] [ComfyUI-0/STDOUT] Adding extra search path gligen C:\StabilityMatrix\Data\Models\GLIGEN
2024-07-11 17:01:37.346 [Debug] [ComfyUI-0/STDOUT] Adding extra search path vae_approx C:\StabilityMatrix\Data\Models\ApproxVAE
2024-07-11 17:01:37.346 [Debug] [ComfyUI-0/STDOUT] Adding extra search path ipadapter C:\StabilityMatrix\Data\Models\IpAdapter
2024-07-11 17:01:37.346 [Debug] [ComfyUI-0/STDOUT] Adding extra search path ipadapter C:\StabilityMatrix\Data\Models\InvokeIpAdapters15
2024-07-11 17:01:37.346 [Debug] [ComfyUI-0/STDOUT] Adding extra search path ipadapter C:\StabilityMatrix\Data\Models\InvokeIpAdaptersXl
2024-07-11 17:01:37.346 [Debug] [ComfyUI-0/STDOUT] Adding extra search path prompt_expansion C:\StabilityMatrix\Data\Models\PromptExpansion
2024-07-11 17:01:37.348 [Debug] [ComfyUI-0/STDOUT] Adding extra search path checkpoints C:\StabilityMatrix\Data\Models\StableDiffusion
2024-07-11 17:01:37.348 [Debug] [ComfyUI-0/STDOUT] Adding extra search path vae C:\StabilityMatrix\Data\Models\VAE
2024-07-11 17:01:37.348 [Debug] [ComfyUI-0/STDOUT] Adding extra search path vae C:\StabilityMatrix\Data\Models\VAE
2024-07-11 17:01:37.348 [Debug] [ComfyUI-0/STDOUT] Adding extra search path loras C:\StabilityMatrix\Data\Models\Lora
2024-07-11 17:01:37.349 [Debug] [ComfyUI-0/STDOUT] Adding extra search path loras C:\StabilityMatrix\Data\Models\Lora
2024-07-11 17:01:37.349 [Debug] [ComfyUI-0/STDOUT] Adding extra search path loras C:\StabilityMatrix\Data\Models\LyCORIS
2024-07-11 17:01:37.349 [Debug] [ComfyUI-0/STDOUT] Adding extra search path upscale_models C:\StabilityMatrix\Data\Models\ESRGAN
2024-07-11 17:01:37.349 [Debug] [ComfyUI-0/STDOUT] Adding extra search path upscale_models C:\StabilityMatrix\Data\Models\RealESRGAN
2024-07-11 17:01:37.349 [Debug] [ComfyUI-0/STDOUT] Adding extra search path upscale_models C:\StabilityMatrix\Data\Models\SwinIR
2024-07-11 17:01:37.349 [Debug] [ComfyUI-0/STDOUT] Adding extra search path upscale_models C:\StabilityMatrix\Data\Models\upscale-models
2024-07-11 17:01:37.349 [Debug] [ComfyUI-0/STDOUT] Adding extra search path upscale_models C:\StabilityMatrix\Data\Models\upscale_models
2024-07-11 17:01:37.349 [Debug] [ComfyUI-0/STDOUT] Adding extra search path embeddings C:\StabilityMatrix\Data\Models\TextualInversion
2024-07-11 17:01:37.349 [Debug] [ComfyUI-0/STDOUT] Adding extra search path embeddings C:\StabilityMatrix\Data\Models\embeddings
2024-07-11 17:01:37.349 [Debug] [ComfyUI-0/STDOUT] Adding extra search path hypernetworks C:\StabilityMatrix\Data\Models\hypernetworks
2024-07-11 17:01:37.349 [Debug] [ComfyUI-0/STDOUT] Adding extra search path controlnet C:\StabilityMatrix\Data\Models\ControlNet
2024-07-11 17:01:37.349 [Debug] [ComfyUI-0/STDOUT] Adding extra search path controlnet C:\StabilityMatrix\Data\Models\ControlNet
2024-07-11 17:01:37.349 [Debug] [ComfyUI-0/STDOUT] Adding extra search path clip_vision C:\StabilityMatrix\Data\Models\InvokeClipVision
2024-07-11 17:01:37.349 [Debug] [ComfyUI-0/STDOUT] Adding extra search path clip_vision C:\StabilityMatrix\Data\Models\clip_vision
2024-07-11 17:01:37.349 [Debug] [ComfyUI-0/STDOUT] Adding extra search path clip C:\StabilityMatrix\Data\Models\clip
2024-07-11 17:01:37.349 [Debug] [ComfyUI-0/STDOUT] Adding extra search path unet C:\StabilityMatrix\Data\Models\unet
2024-07-11 17:01:37.349 [Debug] [ComfyUI-0/STDOUT] Adding extra search path gligen C:\StabilityMatrix\Data\Models\gligen
2024-07-11 17:01:37.350 [Debug] [ComfyUI-0/STDOUT] Adding extra search path ipadapter C:\StabilityMatrix\Data\Models\ipadapter
2024-07-11 17:01:37.350 [Debug] [ComfyUI-0/STDOUT] Adding extra search path yolov8 C:\StabilityMatrix\Data\Models\yolov8
2024-07-11 17:01:37.350 [Debug] [ComfyUI-0/STDOUT] Adding extra search path tensorrt C:\StabilityMatrix\Data\Models\tensorrt
2024-07-11 17:01:37.350 [Debug] [ComfyUI-0/STDOUT] Adding extra search path clipseg C:\StabilityMatrix\Data\Models\clipseg
2024-07-11 17:01:37.350 [Debug] [ComfyUI-0/STDOUT] Adding extra search path custom_nodes C:\StabilityMatrix\Data\Packages\SwarmUI\src\BuiltinExtensions\ComfyUIBackend\DLNodes
2024-07-11 17:01:37.350 [Debug] [ComfyUI-0/STDOUT] Adding extra search path custom_nodes C:\StabilityMatrix\Data\Packages\SwarmUI\src\BuiltinExtensions\ComfyUIBackend\ExtraNodes
2024-07-11 17:01:38.583 [Debug] [ComfyUI-0/STDOUT] ### Loading: ComfyUI-Manager (V2.46)
2024-07-11 17:01:38.715 [Debug] [ComfyUI-0/STDOUT] ### ComfyUI Revision: 2353 [ffe0bb0a] | Released on '2024-07-10'
2024-07-11 17:01:38.986 [Debug] [ComfyUI-0/STDOUT] ๏ฟฝ[36;20m[comfyui_controlnet_aux] | INFO -> Using ckpts path: C:\StabilityMatrix\Data\Packages\SwarmUI\src\BuiltinExtensions\ComfyUIBackend\DLNodes\comfyui_controlnet_aux\ckpts๏ฟฝ[0m
2024-07-11 17:01:38.986 [Debug] [ComfyUI-0/STDOUT] ๏ฟฝ[36;20m[comfyui_controlnet_aux] | INFO -> Using symlinks: False๏ฟฝ[0m
2024-07-11 17:01:38.986 [Debug] [ComfyUI-0/STDOUT] ๏ฟฝ[36;20m[comfyui_controlnet_aux] | INFO -> Using ort providers: ['CUDAExecutionProvider', 'DirectMLExecutionProvider', 'OpenVINOExecutionProvider', 'ROCMExecutionProvider', 'CPUExecutionProvider', 'CoreMLExecutionProvider']๏ฟฝ[0m
2024-07-11 17:01:39.190 [Debug] [ComfyUI-0/STDOUT] [ComfyUI-Manager] default cache updated: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/github-stats.json
2024-07-11 17:01:39.191 [Debug] [ComfyUI-0/STDOUT] [ComfyUI-Manager] default cache updated: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/alter-list.json
2024-07-11 17:01:39.202 [Debug] [ComfyUI-0/STDOUT] [ComfyUI-Manager] default cache updated: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/model-list.json
2024-07-11 17:01:39.239 [Debug] [ComfyUI-0/STDOUT] [ComfyUI-Manager] default cache updated: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/extension-node-map.json
2024-07-11 17:01:39.262 [Debug] [ComfyUI-0/STDOUT] [ComfyUI-Manager] default cache updated: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/custom-node-list.json
2024-07-11 17:01:39.556 [Debug] [ComfyUI-0/STDOUT] C:\StabilityMatrix\Data\Packages\SwarmUI\src\BuiltinExtensions\ComfyUIBackend\DLNodes\comfyui_controlnet_aux\node_wrappers\dwpose.py:26: UserWarning: DWPose: Onnxruntime not found or doesn't come with acceleration providers, switch to OpenCV with CPU device. DWPose might run very slowly
2024-07-11 17:01:39.556 [Debug] [ComfyUI-0/STDOUT]   warnings.warn("DWPose: Onnxruntime not found or doesn't come with acceleration providers, switch to OpenCV with CPU device. DWPose might run very slowly")
2024-07-11 17:01:41.211 [Debug] [ComfyUI-0/STDOUT] 
2024-07-11 17:01:41.211 [Debug] [ComfyUI-0/STDOUT] Import times for custom nodes:
2024-07-11 17:01:41.211 [Debug] [ComfyUI-0/STDOUT]    0.0 seconds: C:\StabilityMatrix\Data\Packages\SwarmUI\src\BuiltinExtensions\ComfyUIBackend\DLNodes\sd-dynamic-thresholding
2024-07-11 17:01:41.211 [Debug] [ComfyUI-0/STDOUT]    0.0 seconds: C:\StabilityMatrix\Data\Packages\ComfyUI\custom_nodes\ComfyUI-Inpaint-CropAndStitch
2024-07-11 17:01:41.211 [Debug] [ComfyUI-0/STDOUT]    0.0 seconds: C:\StabilityMatrix\Data\Packages\ComfyUI\custom_nodes\websocket_image_save.py
2024-07-11 17:01:41.211 [Debug] [ComfyUI-0/STDOUT]    0.0 seconds: C:\StabilityMatrix\Data\Packages\SwarmUI\src\BuiltinExtensions\ComfyUIBackend\DLNodes\ComfyUI-SAI_API
2024-07-11 17:01:41.211 [Debug] [ComfyUI-0/STDOUT]    0.0 seconds: C:\StabilityMatrix\Data\Packages\SwarmUI\src\BuiltinExtensions\ComfyUIBackend\DLNodes\ComfyUI_IPAdapter_plus
2024-07-11 17:01:41.211 [Debug] [ComfyUI-0/STDOUT]    0.1 seconds: C:\StabilityMatrix\Data\Packages\SwarmUI\src\BuiltinExtensions\ComfyUIBackend\ExtraNodes\SwarmComfyCommon
2024-07-11 17:01:41.211 [Debug] [ComfyUI-0/STDOUT]    0.3 seconds: C:\StabilityMatrix\Data\Packages\ComfyUI\custom_nodes\ComfyUI-Manager
2024-07-11 17:01:41.211 [Debug] [ComfyUI-0/STDOUT]    0.7 seconds: C:\StabilityMatrix\Data\Packages\SwarmUI\src\BuiltinExtensions\ComfyUIBackend\DLNodes\comfyui_controlnet_aux
2024-07-11 17:01:41.211 [Debug] [ComfyUI-0/STDOUT]    1.5 seconds: C:\StabilityMatrix\Data\Packages\SwarmUI\src\BuiltinExtensions\ComfyUIBackend\ExtraNodes\SwarmComfyExtra
2024-07-11 17:01:41.211 [Debug] [ComfyUI-0/STDOUT] 
2024-07-11 17:01:41.218 [Debug] [ComfyUI-0/STDOUT] Starting server
2024-07-11 17:01:41.218 [Debug] [ComfyUI-0/STDOUT] 
2024-07-11 17:01:41.218 [Debug] [ComfyUI-0/STDOUT] To see the GUI go to: http://127.0.0.1:7821
2024-07-11 17:01:43.930 [Debug] Comfy backend 0 using model folder format: backslash \ due to model ipadapter\ip-adapter-faceid-plus_sd15_lora.safetensors
2024-07-11 17:01:43.932 [Debug] ComfyUI-0 self-start port 7821 loop ending (should now be alive)
2024-07-11 17:01:44.415 [Debug] Comfy backend 0 using model folder format: backslash \ due to model ipadapter\ip-adapter-faceid-plus_sd15_lora.safetensors
2024-07-11 17:01:44.422 [Debug] Data refreshed!
2024-07-11 17:02:41.842 [Info] User local requested 1 image with model 'epicphotogasm_ultimateFidelity.safetensors'...
2024-07-11 17:02:41.848 [Debug] [BackendHandler] Backend request #1 for model epicphotogasm_ultimateFidelity.safetensors, maxWait=7.00:00:00.
2024-07-11 17:02:41.854 [Debug] [BackendHandler] backend #0 will load a model: epicphotogasm_ultimateFidelity.safetensors, with 1 requests waiting for 0 seconds
2024-07-11 17:02:43.948 [Debug] [ComfyUI-0/STDOUT] got prompt
2024-07-11 17:02:44.143 [Debug] [ComfyUI-0/STDOUT] model_type EPS
2024-07-11 17:02:44.525 [Debug] [ComfyUI-0/STDOUT] Using pytorch attention in VAE
2024-07-11 17:02:44.527 [Debug] [ComfyUI-0/STDOUT] Using pytorch attention in VAE
2024-07-11 17:02:45.319 [Debug] [ComfyUI-0/STDOUT] Requested to load AutoencoderKL
2024-07-11 17:02:45.319 [Debug] [ComfyUI-0/STDOUT] Loading 1 new model
2024-07-11 17:02:46.110 [Debug] [ComfyUI-0/STDOUT] Prompt executed in 2.16 seconds
2024-07-11 17:02:46.267 [Debug] [BackendHandler] backend #0 loaded model, returning to pool
2024-07-11 17:02:46.905 [Debug] [BackendHandler] Backend request #1 found correct model on #0
2024-07-11 17:02:46.905 [Debug] [BackendHandler] Backend request #1 finished.
2024-07-11 17:02:48.463 [Debug] [ComfyUI-0/STDOUT] got prompt
2024-07-11 17:02:49.508 [Debug] [ComfyUI-0/STDOUT] Warning: Ran out of memory when regular VAE encoding, retrying with tiled VAE encoding.
Swarm

Other

No response

Regression - Unable to properly connect SwarmInputDropdown node to Upscale Image (using Model)

I wanted to wait until after the move to the new repo to post this. It seems that sometime after you made it so one could connect a dropdown node to the upscale image node to make a dropdown menu to select a ESRGAN model in the Simple tab, it broke sometime after. Now, not even using the reroute node to forcefully connect the two seems to work anymore. I don't consider this a big deal for me personally but I feel it should be reported as an issue. I think reverting to the previous behavior (needing to use the reroute node) would be better if that's what needs to be done.

Screenshot 2024-06-22 225730
Screenshot 2024-06-22 225745
Screenshot 2024-06-22 225830

ReVision/IPAdapter images cannot be deleted individually

Feature Idea

Users currently have no way to individually remove a specific uploaded image if more than one has been uploaded into the image prompt area. The current workaround for this is to click the Clear images button and re-add all but the image you want to delete, which is not a good user experience.

Instead, there should be X button at the top-right of each uploaded image in the prompt image area, that lets users to remove/delete that specific image.

This isn't very complicated, so I am happy to add this myself, but I am posting this here to get a general thumbs up/down approval on the concept before I add something the Swarm team doesn't want, or if there is an alternate idea for this functionality. ๐Ÿ™‚

Other

No response

Editing model metadata removes .json file

Expected Behavior

When editing model metadata, the corresponding .json file should remain, updated with the new edits.

Actual Behavior

After saving edited metadata, the corresponding .json file is deleted.

Steps to Reproduce

Download a model. For the sake of speed, I chose a random one from Civit which is also pretty small at 54.76 MB, so it's quick: Jade Beyond Good and Evil - v1.0

Open a file manager in the location it saved to. Observe that there is both a .safetensors file and a corresponding .json file.

In Models tab, click the menu hamburger and Edit Metadata. Change the name right at the top to something else and save it.

I changed it from the default:

Jade Beyond Good and Evil - v1.0

to:

Jade Beyond Good and Evil v1.0

In the file manager, notice that the .json file has now disappeared.

After stop/start of Swarm, the thumbnail stays. Someone mentioned here about Swarm changing the metadata of models by writing data into them and that due to this the hash would no longer match to Civit. Presumably this is why the thumbnail and model info stays, because it's now inside the .safetensors file itself? Plus, this kind of makes the .json file itself redundant since it appear unnecessary.

Regardless, a .json file is created by Model Downloader and then unexpectedly deleted which is why I'm filing this as a bug.

Debug Logs

2024-07-04 20:58:46.577 [Debug] Added Civitai API Key to download request. Original URL: https://civitai.com/api/download/models/619731
2024-07-04 20:58:48.818 [Debug] Comfy backend 0 using model folder format: forward slash / as no backslash was found
2024-07-04 20:58:48.902 [Debug] Model sdxlpony/Jade Beyond Good and Evil - v10.safetensors seems to match type Stable Diffusion XL 1.0-Base LoRA
2024-07-04 20:58:49.286 [Debug] Data refreshed!
2024-07-04 20:59:31.733 [Debug] Will reapply metadata for model /config/07-StableSwarm/StableSwarmUI/Models/Lora/sdxlpony/Jade Beyond Good and Evil - v10.safetensors
2024-07-04 20:59:32.145 [Debug] Completed metadata update for /config/07-StableSwarm/StableSwarmUI/Models/Lora/sdxlpony/Jade Beyond Good and Evil - v10.safetensors

Other

Interestingly, I deleted and redownloaded that model just to test doing this again. When I went to edit the metadata, following the steps above, I found that the name was already listed as 'Jade Beyond Good and Evil v1.0' - without the dash. Does this mean the metadata is also stored somewhere else, maybe in 'model_metadata.ldb'? If a user goes to Utilities -> Info -> Reset All Metadata that data would be wiped out?

Update documentation in this repository

Mainly move/copy documentation from the stable repository to this one, so there's no need to keep track of two different repositories.

Also, I noticed that the docs are pretty lacking in terms of making use of custom workflows. For example the hidden mechanism of naming primitive nodes as SwarmUI: Prompt.

Model Downloader enhancements

Feature Idea

Sometimes when downloading through Utilities -> Model Downloader, the speed will be at a crawl. Due to their size, when downloading a checkpoint this can mean it takes a very long time. I have a gigabit connection so I'm used to checkpoints arriving in around three minutes or less. When this crawl pace effect happens it can take literally hours to complete. In fact, when this happens I now restart the container (I use a Docker version) and, after trying the download again, it often comes through at a much more reasonable speed.

In Model Downloader, there is a 'Download' button and that's it.

  1. So, part one of my feature requests is to add a cancel button to the model downloader.

If it's at all possible, maybe even a Retry/Resume button as well. This could check for 'ModelName.download.tmp' and resume the download, or overwrite if resume not possible.

I'm a convert from A1111 and I've been massively spoilt by CivitAi Browser+

One of the things that makes that extension such a joy is that it uses Aria2 for downloading which uses multiple threads at once. Every time I've used CivitAi Browser+ my bandwidth has been maxed out every time so Aria2 does work well with CivitAI. There's a whole Issue where Aria2 is discussed in depth.

  1. So a secondary feature request is to add Aria2 to the model downloader.

  2. Thirdly, this might be asking a lot but basically, I'd like to see CivitAI Browser+ integrated into SwarmUI in some capacity. Its model management features are something I sorely miss.

Other

No response

Editing model metadata affects model hash for Civitai

Hey there,

I was taking a look around how SwarmUI gets its model metadata and noticed that it writes it into the .safetensors file headers when you edit the metadata directly. I do see there is the Stability AI Model Metadata Standard Specification that describes this, but I was wondering whether this could cause issues with other applications that rely on the hash to link back to Civitai and whether this has been taken into consideration?

Since the hash Civitai uses is based off the contents of the entire file (including the headers), it seems like modifying the headers would affect the hash and you'd no longer be able to link the file back to the Civitai source.

Some examples:

Interested to hear your thoughts.

Inpainting (with mask shrink grow) & segmenting should use the model native resolution (or current resolution settings) IMHO

Hi!
Awesome work with swarmUI.
It's almost perfect for my needs apart for an issue with inpainting and segmenting.

Sometime when using inpainting with mask shrink grow, the inpaint is deformed / low quality.
Looking at the generated workflow, it seems that swarm use the current image resolution for the inpaint:
image

Step to reproduce:
1ยฐ) import a big image (or scale an image to a big resolution)
2ยฐ) inpaint a small part using the mask shrink grow option
3ยฐ) import the workflow (great option for debuging btw)
4ยฐ) check the size of SwarmImageScaleForMP => it's set to the current image resolution

When working in native resolution (eg 1024x1024 for SDXL) it's not an issue.
However when working with a high resolution image, it's problematic because the inpaint resolution can exceed the range of the model and the memory can explode.

Here an example when trying to inpaint a small part of a big image with a sd1.5 model.
After importing it, if I force the native resolution in the workflow we can see that the inpaint lose quality as the resolution grows.
image
(Same seed but Gandy is not recognizable at >1024, the skin is smoother and the glasses frame is deformed)

One solution would be to always use the native resolution in this case:
WorkflowGenerator.cs line 327 :

string scaledImage = CreateNode("SwarmImageScaleForMP", new JObject()
{
["image"] = new JArray() { croppedImage, 0 },
["width"] = UserInput.Get(T2IParamTypes.Model).StandardWidth, // use model native resolution
["height"] = UserInput.Get(T2IParamTypes.Model).StandardHeight,
["can_shrink"] = true // Shrink inpaint if mask is too big
});

It works great but the inpaint is always square (not sure if it's better or not but it should be possible to keep the mask ratio if necessary)

The other solution would be to give the user more control and use the selected resolution in the UI.
I believe some changes in JS part would be necessary as I don't think that these parameters are accessible in the C# function.

Segmenting use the same portion of code but that's great because it suffer the same issue, so both would be fixed.

Let me know what you think and if I should work on a PR.

"Reuse Parameters" does not replace the current LoRAs when the reused image has none

Expected Behavior

When the reused image does not contain any LoRAs, the currently selected LoRAs should be removed to "match" the LoRAs used in the reused image.

Actual Behavior

Any currently selected LoRAs remain selected, even though they were not used in the reused image.

Steps to Reproduce

  1. Select at least 1 LoRA
  2. Select an image which does not contain any LoRAs and click "Reuse Parameters"
  3. See the LoRA from step 1 is still selected

Debug Logs

N/A

Other

No response

[Grid Generator] Add Ctrl+click form pull-down lists to allow multiple selection + delete token

When selecting multiple items, such as Loras or samplers, the current process of individually selecting each item, adding a comma, and repeating can be time-consuming, especially when choosing 10 or 20 items.

I propose implementing a system that allows for multi-selection of items using the standard Ctrl key functionality. This would enable users to select multiple items simultaneously, significantly improving efficiency and reducing the time required for the selection process.

Plus, in the same vein, clicking on a listing will remove the token parameter (like lora or sampler, etc). Same behavior as in the status bar of generate where lora's and presets are stacked, with the token method of adding from options menu and removing with cross

Install script stops at "./launch-linux.sh: line 46: dotnet: command not found" when manually defining dotnet location

Issue: The install script fails to find the dotnet command and halts when using the modifications in the script file to specify a different install location for dotnet. Excerpt from the script file with the modifications in place:

# Note: manual installers that want to avoid home dir, add to both of the below lines: --install-dir $SCRIPT_DIR/.dotnet
./dotnet-install.sh --channel 8.0 --runtime aspnetcore --install-dir $SCRIPT_DIR/.dotnet
./dotnet-install.sh --channel 8.0 --install-dir $SCRIPT_DIR/.dotnet

The installer works fine when the location is not manually defined. I fully understand that this may be intended, but in that case the instructions could be made clearer to specify the requirements for using a manually specified location.

Expected behaviour: To find dotnet and continue installation.

OS details: Nobara 40 (based on Fedora 40), x86-64. SwarmUI master on latest commit 487bb19

Logs:

Cloning into 'SwarmUI'...
remote: Enumerating objects: 16754, done.
remote: Counting objects: 100% (16754/16754), done.
remote: Compressing objects: 100% (3647/3647), done.
remote: Total 16754 (delta 13155), reused 16621 (delta 13022), pack-reused 0
Receiving objects: 100% (16754/16754), 11.47 MiB | 1.40 MiB/s, done.
Resolving deltas: 100% (13155/13155), done.
rm: cannot remove 'dotnet-install.sh': No such file or directory
dotnet-install.sh    100% [=============================>]   61.71K  261.21KB/s
                          [Files: 1  Bytes: 61.71K [28.36]
dotnet-install: Attempting to download using aka.ms link https://dotnetcli.azureedge.net/dotnet/aspnetcore/Runtime/8.0.6/aspnetcore-runtime-8.0.6-linux-x64.tar.gz
dotnet-install: Remote file https://dotnetcli.azureedge.net/dotnet/aspnetcore/Runtime/8.0.6/aspnetcore-runtime-8.0.6-linux-x64.tar.gz size is 41925297 bytes.
dotnet-install: Extracting archive from https://dotnetcli.azureedge.net/dotnet/aspnetcore/Runtime/8.0.6/aspnetcore-runtime-8.0.6-linux-x64.tar.gz
dotnet-install: Downloaded file size is 41925297 bytes.
dotnet-install: The remote and local file sizes are equal.
dotnet-install: Installed version is 8.0.6
dotnet-install: Adding to current process PATH: `/home/niroku/Applications/SwarmUI/.dotnet`. Note: This change will be visible only when sourcing script.
dotnet-install: Note that the script does not resolve dependencies during installation.
dotnet-install: To check the list of dependencies, go to https://learn.microsoft.com/dotnet/core/install, select your operating system and check the "Dependencies" section.
dotnet-install: Installation finished successfully.
dotnet-install: Attempting to download using aka.ms link https://dotnetcli.azureedge.net/dotnet/Sdk/8.0.302/dotnet-sdk-8.0.302-linux-x64.tar.gz
dotnet-install: Remote file https://dotnetcli.azureedge.net/dotnet/Sdk/8.0.302/dotnet-sdk-8.0.302-linux-x64.tar.gz size is 222084318 bytes.
dotnet-install: Extracting archive from https://dotnetcli.azureedge.net/dotnet/Sdk/8.0.302/dotnet-sdk-8.0.302-linux-x64.tar.gz
dotnet-install: Downloaded file size is 222084318 bytes.
dotnet-install: The remote and local file sizes are equal.
dotnet-install: Installed version is 8.0.302
dotnet-install: Adding to current process PATH: `/home/niroku/Applications/SwarmUI/.dotnet`. Note: This change will be visible only when sourcing script.
dotnet-install: Note that the script does not resolve dependencies during installation.
dotnet-install: To check the list of dependencies, go to https://learn.microsoft.com/dotnet/core/install, select your operating system and check the "Dependencies" section.
dotnet-install: Installation finished successfully.
cat: src/bin/last_build: No such file or directory


WARNING: You did a git pull without building. Will now build for you...

mv: cannot stat './src/bin/live_release': No such file or directory
./launch-linux.sh: line 37: dotnet: command not found
./launch-linux.sh: line 39: src/bin/last_build: No such file or directory
./launch-linux.sh: line 46: dotnet: command not found

Android Termux

I can't get this to install on linux I keep getting this error

mv: cannot stat './src/bin/live_release': No such file or directory
GC heap initialization failed with error 0x8007000E
Failed to create CoreCLR, HRESULT: 0x8007000E
./launch-linux.sh: line 40: src/bin/last_build: No such file or directory
GC heap initialization failed with error 0x8007000E
Failed to create CoreCLR, HRESULT: 0x8007000E

Please respond asap I want to install this today. This the 3rd time I've tried and I have more ram available

[GridGen] A toggle to skip generation of images when the Lora architecture doesn't match base model

Feature Idea

It can be useful to run grids against different model types, while also using Loras as parameters.

However, this leads to a subset of generations being "useless" because the Loras were not applied to the primary model due to tensor shape incompatibility.

It could be more efficient if there were an option (either globally or per grid generation) that would tell the server to skip the generations where the primary model/lora combinations were incompatible.

@mcmonkey4eva suggested using the architecture IDs of both the model and lora for this check. As I've noted there are a lot of models with poorly constructed metadata out there, I would selfishly prefer the skip decision to be based on detection of incompatible tensor shapes.

However, even using the metadata architecture ID would be a great efficiency improvement. I suppose in this approach, if the architecture ID was missing from primary model or Lora, the server should default to generating?

Thanks - B

Other

No response

Allow deletion/renaming of models from Model Manager

Feature Idea

In Models, clicking the menu for a model will bring up a menu containing:

Load Now
Set as Refiner
Edit Metadata
Create TensorRT Engine

However, there is no option for 'Delete Model' or 'Rename Model'.

If there was a Delete Model option, it should delete the .safetensors file and the corresponding .json.
If there was a Rename Model option, it should rename the .safetensors file and the corresponding .json.

The reasons I'd like delete option is because whenever I want to delete a model, I have to open up a file manager and go looking for the model. I have a lot of models so I have to make absolutely sure I'm deleting the correct one. Some model names can be very similar. Add to that, I have to hop around between directories if I'm on a cleanout spree.

The reason for the rename option is because I've found one or two models I've downloaded that have characters in their names that have prevented them from showing up in certain places. I think this has been fixed now, or I already renamed the file that wouldn't load properly. I'll obviously report if I come across this again but for now I can't remember which model it was.

Also, even though I can use the filter if I know what I'm looking for, sometimes I only have an idea of what I'm looking for. For example, I might remember something beginning with the word 'The'. You can't really type that into the filter bar as that will return everything containing the word 'The', even in the description, whereas I might want to sort by name and manually scroll through every model beginning with that word. The reason I bring this up is because quite often I download models and forget to check the filename it will save with. Model Downloader doesn't have an option to strip out non-English characters so I end up with especially Chinese and Japanese characters interfering with the sort order. Those can still contain the English model name beginning with the word 'The' but only after a bunch of non-English text I don't understand.

Oh, and emoji... For some reason some people put emoji into model names and if I forget to edit the filename it'll save those as well as Model Downloader doesn't strip those out, either.

As a possibility, maybe even a checkbox beside the filter bar to search only filenames/model names? I see this with wildcards as well. I have a ton of wildcards and sometimes I only want to find ones that have the keyword in the actual filename to narrow the list down by a lot, whereas the filter will search literally everywhere, even keywords inside the wildcards themselves. I mean, it's really handy and I do appreciate this feature a lot, but sometimes it's less handy once you build up a bulky setup.

Other

No response

recycle bin for output

Feature Idea

an option to enable recycle bin deletion for output files in windows and linux
thank you :)

Other

No response

SwarmUI can't use alternate paths to models, lora etc.

3

Your question

I set the paths up in the Server Configuration tab. I reloaded the server. ComfyUI backend seemed to add the paths during launch (?) (See images)

No models found, no loras found, etc. What's happening

1
2
01:55:51.758 [Init] === SwarmUI v0.9.0.1 Starting at 2024-06-28 01:55:51 ===
01:55:51.796 [Init] Prepping extension: SwarmUI.Builtin_ScorersExtension.ScorersExtension...
01:55:51.806 [Init] Prepping extension: SwarmUI.Builtin_ImageBatchToolExtension.ImageBatchToolExtension...
01:55:51.806 [Init] Prepping extension: SwarmUI.Builtin_GridGeneratorExtension.GridGeneratorExtension...
01:55:51.807 [Init] Prepping extension: SwarmUI.Builtin_DynamicThresholding.DynamicThresholdingExtension...
01:55:51.808 [Init] Prepping extension: SwarmUI.Builtin_ComfyUIBackend.ComfyUIBackendExtension...
01:55:51.808 [Init] Prepping extension: SwarmUI.Builtin_AutoWebUIExtension.AutoWebUIBackendExtension...
01:55:51.843 [Init] Parsing command line...
01:55:51.845 [Init] Loading settings file...
01:55:51.870 [Init] Re-saving settings file...
01:55:51.890 [Init] Applying command line settings...
01:55:51.903 [Debug] [Load Time] Initial settings load took 0.14s (0.14s from start)
01:55:51.916 [Debug] [Load Time] Extension PreInit took 0.02s (0.16s from start)
01:55:51.917 [Init] Prepping options...
01:55:52.008 [Debug] [Load Time] Prep Objects took 0.09s (0.25s from start)
01:55:52.009 [Debug] [Load Time] Web PreInit took 0s (0.25s from start)
01:55:52.012 [Init] Current git commit marked as date 2024-06-27 20:09:06
01:55:52.016 [Debug] [Load Time] Extensions Init took 0.02s (0.27s from start)
01:55:52.017 [Debug] [Load Time] Prep Utils took 0s (0.27s from start)
01:55:52.032 [Debug] Local version is 0.9.0.1, remote version is 0.6.4.0, relative is 1
01:55:52.033 [Init] Swarm is up to date! Version 0.9.0.1 is the latest.
01:55:52.050 [Debug] [Load Time] Languages load took 0.03s (0.3s from start)
01:55:52.051 [Init] Loading models list...
01:55:52.071 [Init] CPU Cores: 16 | RAM: 31.92 GiB total, 20.15 GiB available
01:55:52.071 [Init] GPU 0: NVIDIA GeForce RTX 2080 | Temp 35C | Util 26% GPU, 16% Memory | VRAM 8.00 GiB total, 7.57 GiB free, 249.00 MiB used
01:55:52.406 [Debug] [Load Time] Model listing took 0.36s (0.66s from start)
01:55:52.407 [Init] Loading backends...
01:55:52.408 [Init] Loading backends from file...
01:55:52.416 [Debug] [Load Time] Backends took 0s (0.66s from start)
01:55:52.416 [Init] Prepping API...
01:55:52.416 [Init] Initializing backend #0 - ComfyUI Self-Starting...
01:55:52.417 [Init] Backend request handler loop ready...
01:55:52.418 [Debug] [Load Time] API took 0s (0.66s from start)
01:55:52.419 [Init] Prepping webserver...
01:55:52.450 [Debug] [Load Time] [Web] WebApp builder prep took 0.02s (0.02s from start)
01:55:52.491 [Debug] [Load Time] [Web] WebApp build took 0.05s (0.06s from start)
01:55:52.493 [Debug] [Load Time] [Web] exception handler took 0s (0.06s from start)
01:55:52.494 [Debug] [Load Time] [Web] StartStop handler took 0s (0.06s from start)
01:55:52.495 [Debug] [Load Time] [Web] static files took 0s (0.06s from start)
01:55:52.549 [Debug] [Load Time] [Web] core use calls took 0.06s (0.13s from start)
01:55:52.555 [Debug] [Load Time] [Web] core maps took 0s (0.13s from start)
01:55:52.556 [Init] Scan for web extensions...
01:55:52.559 [Debug] [Load Time] [Web] end took 0s (0.13s from start)
01:55:52.559 [Debug] [Load Time] Web prep took 0.16s (0.81s from start)
01:55:52.560 [Init] Readying extensions for launch...
01:55:52.561 [Debug] [Load Time] Extensions pre-launch took 0s (0.81s from start)
01:55:52.561 [Init] Launching server...
01:55:52.562 [Init] Starting webserver on http://*:7801
01:55:52.604 [Debug] [Load Time] Web launch took 0.03s (0.84s from start)
01:55:52.605 [Init] Program is running.
01:55:53.111 [Init] Launch web browser...
01:55:53.354 [Debug] [comfy node pull (ComfyUI-SAI_API)/STDOUT] Already up to date.
01:55:53.360 [Info] Self-Start comfy node pull (ComfyUI-SAI_API) exited properly.
01:55:53.361 [Debug] Status of comfy node pull (ComfyUI-SAI_API) after process end is RUNNING
01:55:53.376 [Debug] [comfy node pull (sd-dynamic-thresholding)/STDOUT] Already up to date.
01:55:53.386 [Debug] Status of comfy node pull (sd-dynamic-thresholding) after process end is RUNNING
01:55:53.387 [Info] Self-Start comfy node pull (sd-dynamic-thresholding) exited properly.
01:55:54.194 [Debug] [comfy node pull (ComfyUI-SAI_API)/STDOUT] Already up to date.
01:55:54.202 [Debug] Status of comfy node pull (ComfyUI-SAI_API) after process end is RUNNING
01:55:54.204 [Info] Self-Start comfy node pull (ComfyUI-SAI_API) exited properly.
01:55:54.922 [Info] Creating new admin session 'local' for ::1
01:55:55.339 [Debug] Request for Stable-Diffusion model OfficialStableDiffusion/sd_xl_base_1.0 rejected as not found.
01:55:55.890 [Debug] Request for Stable-Diffusion model OfficialStableDiffusion/sd_xl_base_1.0 rejected as not found.
01:55:58.223 [Debug] [ComfyUI (Git Pull)/STDOUT] Already up to date.
01:55:58.229 [Debug] Status of ComfyUI (Git Pull) after process end is RUNNING
01:55:58.230 [Info] Self-Start ComfyUI (Git Pull) exited properly.
01:55:59.207 [Debug] [comfy node pull (sd-dynamic-thresholding)/STDOUT] Already up to date.
01:55:59.213 [Debug] Status of comfy node pull (sd-dynamic-thresholding) after process end is RUNNING
01:55:59.214 [Info] Self-Start comfy node pull (sd-dynamic-thresholding) exited properly.
01:55:59.216 [Debug] Requested generic launch of dlbackend/comfy/ComfyUI/main.py on GPU 0 from ComfyUI-0
01:55:59.221 [Debug] (ComfyUI-0 launch) Adding path D:\SwarmUI\dlbackend\comfy\python_embeded
01:55:59.221 [Debug] (ComfyUI-0 launch) Will use python: D:\SwarmUI\dlbackend\comfy\python_embeded\python.exe
01:55:59.225 [Init] Self-Start ComfyUI-0 on port 7821 is loading...
01:56:01.134 [Debug] [ComfyUI-0/STDERR] Total VRAM 8192 MB, total RAM 32684 MB
01:56:01.135 [Debug] [ComfyUI-0/STDERR] pytorch version: 2.3.1+cu121
01:56:01.144 [Debug] [ComfyUI-0/STDERR] Set vram state to: NORMAL_VRAM
01:56:01.147 [Debug] [ComfyUI-0/STDERR] Device: cuda:0 NVIDIA GeForce RTX 2080 : cudaMallocAsync
01:56:02.105 [Debug] [ComfyUI-0/STDERR] Using pytorch cross attention
01:56:03.147 [Debug] [ComfyUI-0/STDERR] Adding extra search path checkpoints D:\A1111\stable-diffusion-webui\Stable-Diffusion
01:56:03.149 [Debug] [ComfyUI-0/STDERR] Adding extra search path vae D:\A1111\stable-diffusion-webui\VAE
01:56:03.149 [Debug] [ComfyUI-0/STDERR] Adding extra search path vae D:\A1111\stable-diffusion-webui\Models\VAE
01:56:03.150 [Debug] [ComfyUI-0/STDERR] Adding extra search path loras D:\A1111\stable-diffusion-webui\Lora
01:56:03.150 [Debug] [ComfyUI-0/STDERR] Adding extra search path loras D:\A1111\stable-diffusion-webui\Models\Lora
01:56:03.151 [Debug] [ComfyUI-0/STDERR] Adding extra search path loras D:\A1111\stable-diffusion-webui\Models\LyCORIS
01:56:03.152 [Debug] [ComfyUI-0/STDERR] Adding extra search path upscale_models D:\A1111\stable-diffusion-webui\Models\ESRGAN
01:56:03.152 [Debug] [ComfyUI-0/STDERR] Adding extra search path upscale_models D:\A1111\stable-diffusion-webui\Models\RealESRGAN
01:56:03.153 [Debug] [ComfyUI-0/STDERR] Adding extra search path upscale_models D:\A1111\stable-diffusion-webui\Models\SwinIR
01:56:03.153 [Debug] [ComfyUI-0/STDERR] Adding extra search path upscale_models D:\A1111\stable-diffusion-webui\Models\upscale-models
01:56:03.154 [Debug] [ComfyUI-0/STDERR] Adding extra search path upscale_models D:\A1111\stable-diffusion-webui\Models\upscale_models
01:56:03.154 [Debug] [ComfyUI-0/STDERR] Adding extra search path embeddings D:\A1111\stable-diffusion-webui\embeddings
01:56:03.155 [Debug] [ComfyUI-0/STDERR] Adding extra search path embeddings D:\A1111\stable-diffusion-webui\Models\embeddings
01:56:03.156 [Debug] [ComfyUI-0/STDERR] Adding extra search path hypernetworks D:\A1111\stable-diffusion-webui\Models\hypernetworks
01:56:03.156 [Debug] [ComfyUI-0/STDERR] Adding extra search path controlnet D:\A1111\stable-diffusion-webui\controlnet
01:56:03.157 [Debug] [ComfyUI-0/STDERR] Adding extra search path controlnet D:\A1111\stable-diffusion-webui\Models\ControlNet
01:56:03.157 [Debug] [ComfyUI-0/STDERR] Adding extra search path clip_vision D:\A1111\stable-diffusion-webui\Models\clip_vision
01:56:03.158 [Debug] [ComfyUI-0/STDERR] Adding extra search path clip_vision D:\A1111\stable-diffusion-webui\Models\clip_vision
01:56:03.159 [Debug] [ComfyUI-0/STDERR] Adding extra search path clip D:\A1111\stable-diffusion-webui\Models\clip
01:56:03.159 [Debug] [ComfyUI-0/STDERR] Adding extra search path unet D:\A1111\stable-diffusion-webui\Models\unet
01:56:03.160 [Debug] [ComfyUI-0/STDERR] Adding extra search path gligen D:\A1111\stable-diffusion-webui\Models\gligen
01:56:03.161 [Debug] [ComfyUI-0/STDERR] Adding extra search path ipadapter D:\A1111\stable-diffusion-webui\Models\ipadapter
01:56:03.163 [Debug] [ComfyUI-0/STDERR] Adding extra search path yolov8 D:\A1111\stable-diffusion-webui\Models\yolov8
01:56:03.164 [Debug] [ComfyUI-0/STDERR] Adding extra search path tensorrt D:\A1111\stable-diffusion-webui\Models\tensorrt
01:56:03.164 [Debug] [ComfyUI-0/STDERR] Adding extra search path clipseg D:\A1111\stable-diffusion-webui\Models\clipseg
01:56:03.165 [Debug] [ComfyUI-0/STDERR] Adding extra search path custom_nodes D:\SwarmUI\src\BuiltinExtensions\ComfyUIBackend\DLNodes
01:56:03.166 [Debug] [ComfyUI-0/STDERR] Adding extra search path custom_nodes D:\SwarmUI\src\BuiltinExtensions\ComfyUIBackend\ExtraNodes
01:56:04.887 [Debug] [ComfyUI-0/STDERR]
01:56:04.889 [Debug] [ComfyUI-0/STDERR] Import times for custom nodes:
01:56:04.889 [Debug] [ComfyUI-0/STDERR] 0.0 seconds: D:\SwarmUI\dlbackend\comfy\ComfyUI\custom_nodes\websocket_image_save.py
01:56:04.890 [Debug] [ComfyUI-0/STDERR] 0.0 seconds: D:\SwarmUI\src\BuiltinExtensions\ComfyUIBackend\DLNodes\ComfyUI-SAI_API
01:56:04.891 [Debug] [ComfyUI-0/STDERR] 0.0 seconds: D:\SwarmUI\src\BuiltinExtensions\ComfyUIBackend\DLNodes\sd-dynamic-thresholding
01:56:04.892 [Debug] [ComfyUI-0/STDERR] 0.1 seconds: D:\SwarmUI\src\BuiltinExtensions\ComfyUIBackend\ExtraNodes\SwarmComfyCommon
01:56:04.892 [Debug] [ComfyUI-0/STDERR] 1.2 seconds: D:\SwarmUI\src\BuiltinExtensions\ComfyUIBackend\ExtraNodes\SwarmComfyExtra
01:56:04.893 [Debug] [ComfyUI-0/STDERR]
01:56:04.893 [Debug] [ComfyUI-0/STDERR] Starting server
01:56:04.894 [Debug] [ComfyUI-0/STDERR]
01:56:04.895 [Debug] [ComfyUI-0/STDERR] To see the GUI go to: http://127.0.0.1:7821
01:56:07.374 [Debug] Comfy backend 0 using model folder format: forward slash / as no backslash was found
01:56:07.377 [Init] Self-Start ComfyUI-0 on port 7821 started.
01:56:07.377 [Debug] ComfyUI-0 self-start port 7821 loop ending (should now be alive)
01:56:07.819 [Debug] Comfy backend 0 using model folder format: forward slash / as no backslash was found
01:56:08.245 [Debug] Data refreshed!

Logs

No response

Other

No response

Incorrect aspect ratio when using upscale 2x button

Expected Behavior

Image metadata contains the correct aspect ratio matching the original image when using "Upscale 2x"

Actual Behavior

Image metadata contains the aspect ratio that is selected in the parameters on the left of the UI.

Steps to Reproduce

  1. Generate an image (say with aspect ratio 1:1)
  2. Change the aspect ratio parameter on the left of the UI (e.g. 2:3)
  3. Select the previously generated image and click "Upscale 2x"
  4. Notice the new image is correctly 2x the size of the original with 1:1 aspect ratio, but the metadata has 2:3 as the aspect ratio.

Debug Logs

N/A

Other

When you try load the image back in with "Reuse parameters" it then tries to load it with the incorrect aspect ratio thats in the metadata.

Feature Request: Paste from Clipboard for Initial Image (img2img) or image in-paint

There doesn't appear to be any obvious way to paste an image from the clipboard to use as the Initial image for img2img or in-painting.
Instead, ctrl+v pastes the image to be read by CLIP. There should be an option to also use it as the initial image.

This breaks the workflow for anyone who uses external image editors to make specific edits to images before feeding them back into img2img, without the need to save the intermediary edited photo.

For example, my workflow when using Auto1111 was to make quick edits to a photo in Photoshop, copy (not save) the entire image and then paste into Img2Img or for in-painting, generate, copy, Photoshop, rinse/repeat until I'm happy with the results.

Multi-user setup

Is there a rough guide on how to enable multi user support?
I see references to user id's, and X-SWARM-USER_ID headers and a --user_id flag.

Do I simply need to expose my comfy service and launch the SwarmUI with --user_id whatever-user-id, or do I simply just set a "master" swarm as a backend (or both)?

Feature Request: Support small form factor devices

Feature Idea

The UI is currently designed for use on desktop devices, and is rendered appropriately for that use-case.

For non-desktop devices such as tablets or other mobile devices, the UI is not rendered in a user-friendly way. Some support for at least basic text-to-image generation on small form factors would be greatly appreciated.

Missing LoRAs causing issues when reusing parameters

Expected Behavior

  1. Number of loraweights matches the number of loras applied to the generated image
  2. Lora weight is updated correctly when "Reuse parameters" is pressed
  3. Lora weight in the UI matches the weight used in the image generation

Actual Behavior

When "Reuse Parameters" is pressed with a missing lora:
* The remaining LoRA gets added to "current loras" but the weight will not update in the UI to match the weight from the reused image.

And then when an image is generated afterwards:
* The loraweights still include the missing lora's weight.
* The weight of the remaining lora applied does not match the weight used in the original image

Steps to Reproduce

  1. Generate an image that uses 2 loras. To demonstrate this clearer, set them to different weights (and don't use 1.0). Lets say we pick 0.1 for lora A and 0.9 for lora B.
  2. Rename or move lora A so it is "missing"
  3. Refresh lora list and then refresh the browser
  4. Notice lora A is now gone from the "current loras" list and the weight of lora B has been reset to 1.0 in the UI.
  5. Select the image you just generated and click "reuse parameters"
  6. Notice that in "current loras" that:
    • lora A from the original generation is not there (this is expected because it has been moved and is now "missing")
    • lora B from the original generation is there but the weight is not updated (still shows 1.0 instead of 0.9).
  7. Generate another image
  8. Notice the following issues:
    • The image metadata contains 1 lora (lora B) but still the 2 loraweights from the original generation
    • The weight of lora B that was applied to the image was neither 1.0 (as seen in the UI), nor 0.9 (from original generation), but 0.1.

Debug Logs

Nothing relevant in the server logs, but browser console contains:

Ignoring invalid LoRA weights value. Have 1 LoRAs (["<lora name>"]), but 2 weights (0.7,0.8)

Other

Not directly related but when reusing parameters and there is a missing lora, currently it just omits it from the current loras. It might nice to have it still in the "current loras" but faded out. This would make it easier to identify that a lora is missing and be a clearer indicator to the user that the reused parameters don't exactly match the image.

Or, just raise a pop up warning.

Yolo segmentation seems to only detect one face

Hi,

First, thank you for this awesome UI! I'm trying to generate an image, where all faces will be fixed, like in the ADetailer extension of A1111.

Here is my prompt:

oil painting of a male actor in a theatre full of people in the 1920s, black short hair with gomina, wearing a hamlet costume, fantasy art by greg olsen
<segment:yolo-face_yolov8m-seg_60.pt>

However, it just fixes the face of my main character, not all faces in the crowd. I tried to lower the detection threshold, but still, only one face seems to be detected (other faces are clearly identifiable though, and ADetailer in A1111 works as expected).

oil painting of a male actor in a theatre full of people in the 1920s, black short hair with gomina, wearing a hamlet costume, fantasy art by greg olsen
<segment:yolo-face_yolov8m-seg_60.pt,0.6,0.2>

Do you have a suggestion to fix this, and have all faces detected, please? Thank you!

Installation: Error handling API request '/API/InstallConfirmWS'

Expected Behavior

Installation with "just install" and all options on default should just install SwarmUI

Actual Behavior

[WebAPI] Error handling API request '/API/InstallConfirmWS' for user 'local': Internal exception: System.IO.IOException: Cannot create 'T:\StableStudio\SwarmUI\dlbackend\comfy' because a file or directory with the same name already exists.

Steps to Reproduce

System:

  • Win11 (22631.3737)

  • dotnet8 installed

  • SwarmUI v0.9.0.1

  • clone https://github.com/mcmonkeyprojects/SwarmUI.git

  • open launch-windows.bat

Log output:

The system cannot find the path specified.
""
""
"WARNING: You did a git pull without building. Will now build for you..."
""
""
The system cannot find the path specified.
The system cannot find the file specified.
error: The source specified has already been added to the list of available package sources. Provide a unique source.


Usage: dotnet nuget add source [arguments] [options]

Arguments:
  PackageSourcePath  Path to the package source.

Options:
  -n|--name                       Name of the source.
  -u|--username                   Username to be used when connecting to an authenticated source.
  -p|--password                   Password to be used when connecting to an authenticated source.
  --store-password-in-clear-text  Enables storing portable package source credentials by disabling password encryption.
  --valid-authentication-types    Comma-separated list of valid authentication types for this source. Set this to basic if the server advertises NTLM or Negotiate and your credentials must be sent using the Basic mechanism, for instance when using a PAT with on-premises Azure DevOps Server. Other valid values include negotiate, kerberos, ntlm, and digest, but these values are unlikely to be useful.
  --protocol-version              The NuGet server protocol version to be used. Currently supported versions are 2 and 3. See https://learn.microsoft.com/nuget/api/overview for information about the version 3 protocol. Defaults to 2 if not specified.
  --configfile                    The NuGet configuration file. If specified, only the settings from this file will be used. If not specified, the hierarchy of configuration files from the current directory will be used. For more information, see https://docs.microsoft.com/nuget/consume-packages/configuring-nuget-behavior.
  -h|--help                       Show help information

  Determining projects to restore...
  Restored T:\StableStudio\SwarmUI\src\SwarmUI.csproj (in 512 ms).
  SwarmUI -> T:\StableStudio\SwarmUI\src\bin\live_release\SwarmUI.dll

Build succeeded.
    0 Warning(s)
    0 Error(s)

Time Elapsed 00:00:04.95
01:15:50.578 [Init] === SwarmUI v0.9.0.1 Starting at 2024-06-28 01:15:50 ===
01:15:50.702 [Init] Prepping extension: SwarmUI.Builtin_ScorersExtension.ScorersExtension...
01:15:50.711 [Init] Prepping extension: SwarmUI.Builtin_ImageBatchToolExtension.ImageBatchToolExtension...
01:15:50.712 [Init] Prepping extension: SwarmUI.Builtin_GridGeneratorExtension.GridGeneratorExtension...
01:15:50.713 [Init] Prepping extension: SwarmUI.Builtin_DynamicThresholding.DynamicThresholdingExtension...
01:15:50.714 [Init] Prepping extension: SwarmUI.Builtin_ComfyUIBackend.ComfyUIBackendExtension...
01:15:50.715 [Init] Prepping extension: SwarmUI.Builtin_AutoWebUIExtension.AutoWebUIBackendExtension...
01:15:50.756 [Init] Parsing command line...
01:15:50.757 [Init] Loading settings file...
01:15:50.758 [Init] No settings file found.
01:15:50.759 [Init] Re-saving settings file...
01:15:50.781 [Init] Applying command line settings...
01:15:50.953 [Init] Prepping options...
01:15:50.974 [Init] Current git commit marked as date 2024-06-27 20:09:06
01:15:51.029 [Init] Swarm is up to date! Version 0.9.0.1 is the latest.
01:15:51.133 [Init] Loading models list...
01:15:51.154 [Init] Loading backends...
01:15:51.156 [Init] Loading backends from file...
01:15:51.158 [Init] Prepping API...
01:15:51.159 [Init] Backend request handler loop ready...
01:15:51.161 [Init] Prepping webserver...
01:15:51.198 [Init] CPU Cores: 12 | RAM: 31.92 GiB total, 17.83 GiB available
01:15:51.199 [Init] GPU 0: NVIDIA GeForce RTX 3060 Ti | Temp 38C | Util 27% GPU, 31% Memory | VRAM 8.00 GiB total, 6.52 GiB free, 1.32 GiB used
01:15:51.316 [Init] Scan for web extensions...
01:15:51.321 [Init] Readying extensions for launch...
01:15:51.322 [Init] Launching server...
01:15:51.324 [Init] Starting webserver on http://localhost:7801
01:15:51.380 [Init] Program is running.
01:15:51.887 [Init] Launch web browser to install page...
01:15:52.427 [Info] Creating new admin session 'local' for ::1
01:15:57.101 [Init] [Installer] Installation request received, processing...
01:15:57.103 [Init] [Installer] Setting theme to modern_dark.
01:15:57.104 [Init] [Installer] Configuring settings as 'just yourself' install.
01:15:57.105 [Init] [Installer] Downloading ComfyUI backend... please wait...
01:18:39.373 [Init] [Installer] Downloaded! Extracting... (look in terminal window for details)

7-Zip (a) 23.01 (x86) : Copyright (c) 1999-2023 Igor Pavlov : 2023-06-20

Scanning the drive for archives:
1 file, 1551835100 bytes (1480 MiB)

Extracting archive: dlbackend\comfyui_dl.7z
--
Path = dlbackend\comfyui_dl.7z
Type = 7z
Physical Size = 1551835100
Headers Size = 361598
Method = LZMA:25 BCJ2
Solid = +
Blocks = 2

Everything is Ok

Folders: 2932
Files: 29282
Size:       5721481652
Compressed: 1551835100
01:21:17.142 [Error] [WebAPI] Error handling API request '/API/InstallConfirmWS' for user 'local': Internal exception: System.IO.IOException: Cannot create 'T:\StableStudio\SwarmUI\dlbackend\comfy' because a file or directory with the same name already exists.
   at System.IO.FileSystem.MoveDirectory(String sourceFullPath, String destFullPath, Boolean _)
   at System.IO.FileSystem.MoveDirectory(String sourceFullPath, String destFullPath)
   at SwarmUI.WebAPI.BasicAPIFeatures.<InstallConfirmWS>g__moveFolder|3_2() in T:\StableStudio\SwarmUI\src\WebAPI\BasicAPIFeatures.cs:line 187
   at SwarmUI.WebAPI.BasicAPIFeatures.InstallConfirmWS(Session session, WebSocket socket, String theme, String installed_for, String backend, String models, Boolean install_amd, String language) in T:\StableStudio\SwarmUI\src\WebAPI\BasicAPIFeatures.cs:line 210
   at SwarmUI.WebAPI.API.HandleAsyncRequest(HttpContext context) in T:\StableStudio\SwarmUI\src\WebAPI\API.cs:line 124

Debug Logs

There is no running server, therefor now logs available.

Other

No response

install-linux.sh uses wrong path if in a path containing spaces

Issue: If you run the install-linux.sh script in a path that contains spaces, like /home/niroku/Applications/SwarmUI testing/, then the install script fails at the first cd command:
cd: Too many arguments.
and continues executing commands. The SwarmUI does continue installation, just not in the path specified (it uses whatever path the working directory is currently).

Solution 1: The rudimentary fix is to encapsulate all uses of $SCRIPT_DIR in double-quotes:
install-linux.zip
This also needs to be applied to the SwarmUI/launch-linux.sh file as well:
launch-linux.zip
This issue may affect all platforms, but I've only tested this rudimentary fix on Linux. This is the most security-oriented approach, as the script is currently arbitrary commands (intentional or not) can be executed by the script depending on the name of the path installed to, eg. /home/you/lol && cd -- && rm -rf * (though this is arguably self-inflicted).

Solution 2: The rudimentary fix in solution 1 does not account for other parts of the project that may have been programmed with the initial behaviour in mind though, so a less error-prone solution might be to store escaped double-quotes in the SCRIPT_DIR variable itself. In which case, the command to assign the variable can be replaced with:

SCRIPT_DIR=\"$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )\"

in all the files which define that variable (install-linux.sh, launch-linux.sh, launch-macos.sh, etc.). This is the fix involving the fewest modifications to existing files.

Solution 3: Tell users not to use paths that contains spaces.

Extra info: This issue affects manually defined paths as well, which is the initial issue I was actually testing for. So the rudimentary fix for solution 1 would be modified as:

# Note: manual installers that want to avoid home dir, add to both of the below lines: --install-dir "$SCRIPT_DIR/.dotnet"
./launchtools/dotnet-install.sh --channel 8.0 --runtime aspnetcore --install-dir "$SCRIPT_DIR/.dotnet"
./launchtools/dotnet-install.sh --channel 8.0 --install-dir "$SCRIPT_DIR/.dotnet"

If using solution 2, no further modifications are necessary.

Indicate Base-Model family in sub-model dropdowns

Feature Idea

As SwarmUI already does internal analysis/tagging (either via metadata field or by tensor names/etc.) to determine the base model of each sub-model...

I think it would be helpful to add some sort of sign to the subpath autocomplete drop downs that occur in the prompt editor (<embed:... , <lora:..., etc.) as well as the drop downs that occur in the model search boxes (including the grid parameters) that indicate the BASE MODEL that the sub-model was trained on/to work with.

As per discussion, icons would be somewhat more complicated, so perhaps something like a monospaced two-letter code to the left of each sub-path? E.g.

S1 = SD1.4 and SD1.5 (as they are nearly equivalent) and all finetunes.
S2 = SD2.x and all finetunes
XL = SDXL and all finetunes
CA = Stable Cascade...etc.

Note: CivitAI uses SD1 and SD2 similar to S1 and S2 above, which would also be fine...as long as the pathnames don't start looking all janky due to different prefix widths.

XL /negative/Detail++
XL /positive/zPDXL
XL /negative/zPDXL-neg
S1 /negative/EasyNegative

Perhaps also an option to allow the user to override the assignment of extreme finetunes (such as PONY 6 XL or NAI) with a custom indicator such as PD (since that's not strictly determinable via the standardized metadata nor the tensor names). Not really sure there's anything to do automatically other than leave those in the appropriate XL or S1 category.

B

Other

No response

[TEST] Ignore this, testing issue templates - Bug Report

Expected Behavior

i expected to see, stuff

Actual Behavior

i actually saw, other stuff

Steps to Reproduce

to reproduce, do this stuff

Debug Logs

2024-06-25 18:08:54.708 [Init] === SwarmUI v0.9.0.1 Starting at 2024-06-25 18:08:54 ===
2024-06-25 18:08:54.908 [Init] Prepping extension: SwarmUI.Builtin_ScorersExtension.ScorersExtension...
2024-06-25 18:08:54.916 [Init] Prepping extension: SwarmUI.Builtin_ImageBatchToolExtension.ImageBatchToolExtension...
2024-06-25 18:08:54.917 [Init] Prepping extension: SwarmUI.Builtin_GridGeneratorExtension.GridGeneratorExtension...
2024-06-25 18:08:54.918 [Init] Prepping extension: SwarmUI.Builtin_DynamicThresholding.DynamicThresholdingExtension...
2024-06-25 18:08:54.918 [Init] Prepping extension: SwarmUI.Builtin_ComfyUIBackend.ComfyUIBackendExtension...
2024-06-25 18:08:54.919 [Init] Prepping extension: SwarmUI.Builtin_AutoWebUIExtension.AutoWebUIBackendExtension...
2024-06-25 18:08:54.948 [Init] Parsing command line...
2024-06-25 18:08:54.948 [Init] Loading settings file...
2024-06-25 18:08:54.968 [Init] Re-saving settings file...
2024-06-25 18:08:54.986 [Init] Applying command line settings...
2024-06-25 18:08:55.078 [Init] Prepping options...
2024-06-25 18:08:55.102 [Init] Current git commit marked as date 2024-06-26 01:08:40
2024-06-25 18:08:55.209 [Init] Loading models list...
2024-06-25 18:08:55.244 [Init] Swarm is up to date! Version 0.9.0.1 is the latest.

Other

No response

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.