Skip to content

Error in clip_gradients function of G2C.py #1

@carolin-m

Description

@carolin-m

In the clip_gradients function of G2C.py is an error in generating grads and gvars. Originally is written:

grads, gvars = list(zip(*gvs)[0]), list(zip(*gvs)[1])

However, the round brackets are incorrectly set, so that it raises a TypeError: 'zip' object is not subscriptable.
This can be fixed by changing the line to:

grads, gvars = list(zip(*gvs))[0], list(zip(*gvs))[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