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

Refactor generation backend #4201

Merged
merged 70 commits into from
Aug 14, 2023
Merged

Conversation

StAlKeR7779
Copy link
Contributor

What type of PR is this? (check all applicable)

  • Refactor
  • Feature
  • Bug Fix
  • Optimization
  • Documentation Update
  • Community Node Submission

Have you discussed this change with the InvokeAI team?

  • Yes
  • No, because:

Have you updated all relevant documentation?

  • Yes
  • No

Description

  • Remove SDXL raw prompt nodes
  • SDXL and SD1/2 generation merged to same nodes - t2l/l2l
  • Fixed - if no xformers installed we trying to enable attention slicing, ignoring torch-sdp availability
  • Fixed - In SDXL negative prompt now creating zeroed tensor(according to official code)
  • Added mask field to l2l node
  • Removed inpaint node and all legacy code related to this node
  • Pass info about seed in latents, so we can use it to initialize ancestral/sde schedulers
  • t2l and l2l nodes moved from strength to denoising_start/end
  • Removed code for noise threshold(@hipsterusername said that there no plans to restore this feature)
  • Fixed - first preview image now not gray
  • Fixed - report correct total step count in progress, added scheduler order in progress event
  • Added MaskEdge and ColorCorrect nodes (@hipsterusername)

Added/updated tests?

  • Yes
  • No

@keturn
Copy link
Contributor

keturn commented Aug 9, 2023

Can we merge #4175 first?

I admit it's partly my thirst for those sweet line-deletion credits, but also there are a half-dozen different things going on in a single PR here and if we can take advantage of an already-existing PR to cut it down in scope, I think that will make it easier to review.

Copy link
Collaborator

@psychedelicious psychedelicious left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔥

invokeai/app/invocations/compel.py Outdated Show resolved Hide resolved
invokeai/app/invocations/image.py Show resolved Hide resolved
invokeai/app/invocations/image.py Outdated Show resolved Hide resolved
invokeai/app/invocations/latent.py Outdated Show resolved Hide resolved
invokeai/app/invocations/latent.py Outdated Show resolved Hide resolved
invokeai/app/invocations/latent.py Outdated Show resolved Hide resolved
invokeai/app/invocations/latent.py Outdated Show resolved Hide resolved
invokeai/app/invocations/latent.py Outdated Show resolved Hide resolved
invokeai/app/services/events.py Show resolved Hide resolved
invokeai/app/util/step_callback.py Outdated Show resolved Hide resolved
Copy link
Contributor

@keturn keturn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for merging in the other code removal first!

That knocked down the size of this PR a bit, but IMHO it's still too much for a single PR.

There's inpainting stuff that could be done without the SDXL stuff,
the seeding of the stochastic schedulers is an independent issue,
the changes to adjust-memory-efficient-attention could and should be considered and tested on their own--

I've left a few comments so far, but this does not constitute anything near a complete review. I haven't even got to the changes in shared_invokeai_diffusion yet, let alone any of the SDXL.

invokeai/backend/stable_diffusion/diffusers_pipeline.py Outdated Show resolved Hide resolved
invokeai/backend/stable_diffusion/diffusers_pipeline.py Outdated Show resolved Hide resolved
invokeai/app/services/events.py Show resolved Hide resolved
@hipsterusername hipsterusername merged commit cd0e4bc into main Aug 14, 2023
8 checks passed
@hipsterusername hipsterusername deleted the feat/refactor_generation_backend branch August 14, 2023 03:08
@hipsterusername hipsterusername restored the feat/refactor_generation_backend branch August 14, 2023 03:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants