Skip to content

Why the KL Divergence Loss needs to be multiplied by number of classes? #7

@tim5go

Description

@tim5go

KL_loss_fake = F.kl_div(KL_fake_output, uniform_dist)*args.num_classes

I'm bit confused about why you needa multiply the KL divergence loss by the number of classes.
I can't find it from the definition of your paper, could you briefly explain it?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions