Skip to content

torch::jit::script::Module has no zero_grad() #27144

Open
@peastman

Description

@peastman

🐛 Bug

I'm writing a C++ program that loads a module from disk and tries to work with it. Unlike nn::Module, it appears that torch::jit::script::Module has no zero_grad() method. This makes it impossible to do optimization.

Environment

cc @suo

Metadata

Metadata

Assignees

No one assigned

    Labels

    jit-backlogoncall: jitAdd this issue/PR to JIT oncall triage queuetriagedThis issue has been looked at a team member, and triaged and prioritized into an appropriate module

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions