MCPcopy Create free account
hub / github.com/HA-Transformer/MAT / backward

Method backward

fairseq/optim/fp16_optimizer.py:137–146  ·  view source on GitHub ↗

Computes the sum of gradients of the given tensor w.r.t. graph leaves. Compared to :func:`fairseq.optim.FairseqOptimizer.backward`, this function additionally dynamically scales the loss to avoid gradient underflow.

(self, loss)

Source from the content-addressed store, hash-verified

source not stored for this graph (policy: none)

Callers 1

backwardMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected