Skip to content

bug in calc_gradient_penalty? #47

Description

@lezhang-thu

gradient_penalty = ((gradients.norm(2, dim=1) - 1) ** 2).mean() * LAMBDA

Right before this line, it should be added "gradients = gradients.view(BATCH_SIZE, -1)"?

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