Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

[BUG] - Model is reloaded every time seed changes #99

Open
Crodu opened this issue Oct 14, 2024 · 1 comment
Open

[BUG] - Model is reloaded every time seed changes #99

Crodu opened this issue Oct 14, 2024 · 1 comment
Labels
bug Something isn't working help wanted Extra attention is needed

Comments

@Crodu
Copy link

Crodu commented Oct 14, 2024

Description

Model is reloaded every time seed changes.
If you use the seed generator from SD Parameter Generator, ComfyUi always reloads the checkpoint into memory, which makes the generation process slow. Current workaround is using a separated seed generator.

Reproduction steps

  1. Use ParameterGenerator to load checkpoint model in your workflow.
  2. Set a new random seed
  3. See that the checkpoint is always loading at the beggining of every workflow run, as opposed to loading only on the first run

Image file

No response

@Crodu Crodu added the bug Something isn't working label Oct 14, 2024
@receyuki
Copy link
Owner

receyuki commented Feb 4, 2025

I also noticed this issue, but I haven't found a good solution yet. If I change the checkpoint to a class variable, it can prevent repeated loading, but it also means that the checkpoint won't be unloaded by ComfyUI's checkpoint management mechanism. As a result, even if the user removes this node, the loaded checkpoint will remain until the server is restarted.

@receyuki receyuki changed the title [BUG] - title [BUG] - Model is reloaded every time seed changes Feb 4, 2025
@receyuki receyuki added the help wanted Extra attention is needed label Feb 4, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants