Skip to content

The grad of training loss with respect to z_{sem} is zero #63

Open

Description

@ZhangMingKun1

First, thanks for your excellent work!

I've reproduced the model training process outlined in your project. However, during my inspection of the GaussianDiffusionBeatGans.training_losses method (defined in diffusion/base.py), I noticed that the gradient of the loss function with respect to the z_{sem} variable (passed via model_kwargs['cond']) is consistently zero. This raised concern because a zero gradient implies that z_{sem} is not being utilized in the training loss computation, which would essentially prevent the semantic encoder from training.

Could this possibly be a mistake or a misunderstanding on my part? Is this the same in your training process? If not, do you have any valuable ideas of the possible mistake in my reproduction? I would greatly appreciate any insights or clarifications you might be able to provide.

Activity

  1. Kim-Sung-Hun commented on Mar 22, 2024

    @Kim-Sung-Hun

    I have the same problem. When using the render function with a trained model for inference, output remains same regardless of the input image, changing only due to xT.

  2. dsj320 commented on Apr 11, 2024

    @dsj320

    I would like to understand how the author trained the encoder and updated the gradients. Could someone provide me with this information? I would be very grateful for their assistance

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions