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

Inferer modification - save_intermediates clashes with latent shape adjustment in latent diffusion inferers #8343

Merged
merged 11 commits into from
Feb 18, 2025

Conversation

virginiafdez
Copy link
Contributor

Fixes #8334

Description

There was an if save_intermediates missing in the code that was trying to run crop of the latent spaces on the sample function of the Latent Diffusion Inferers (normal one and ControlNet one) even when intermediates aren't created.

Types of changes

  • Non-breaking change (fix or new feature that would not break existing functionality).

Virginia Fernandez and others added 3 commits February 14, 2025 14:36
…fusionInferer when save_intermediates was off but there's need to pad and crop latent space.

Signed-off-by: Virginia Fernandez <[email protected]>
…fusionInferer when save_intermediates was off but there's need to pad and crop latent space.

Signed-off-by: Virginia Fernandez <[email protected]>
@ericspod ericspod requested review from ericspod and KumoLiu February 17, 2025 14:40
@ericspod
Copy link
Member

Thanks for the fix, could we add a unit test to capture this behaviour? We should have one test at least that would fail without this fix but works with it I think.

Copy link
Contributor

@KumoLiu KumoLiu 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 the fix, LGTM.

Virginia Fernandez added 4 commits February 18, 2025 08:01
@KumoLiu
Copy link
Contributor

KumoLiu commented Feb 18, 2025

/build

@KumoLiu
Copy link
Contributor

KumoLiu commented Feb 18, 2025

/build

@KumoLiu KumoLiu enabled auto-merge (squash) February 18, 2025 11:55
@KumoLiu KumoLiu merged commit 0a85eed into Project-MONAI:dev Feb 18, 2025
28 checks passed
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.

LatentDiffusionInferer errors out when save_intermediates = False and padding and cropping is needed
3 participants