mxnet.autograd

Functions

backward(heads[, head_grads, retain_graph, …])

Compute the gradients of heads w.r.t previously marked variables.

get_symbol(x)

Retrieve recorded computation history as Symbol.

grad(heads, variables[, head_grads, …])

Compute the gradients of heads w.r.t variables.

is_recording()

Get status on recording/not recording.

is_training()

Get status on training/predicting.

mark_variables(variables, gradients[, grad_reqs])

Mark NDArrays as variables to compute gradient for autograd.

pause([train_mode])

Returns a scope context to be used in ‘with’ statement for codes that do not need gradients to be calculated.

predict_mode()

Returns a scope context to be used in ‘with’ statement in which forward pass behavior is set to inference mode, without changing the recording states.

record([train_mode])

Returns an autograd recording scope context to be used in ‘with’ statement and captures code that needs gradients to be calculated.

set_recording(is_recording)

Set status to recording/not recording.

set_training(train_mode)

Set status to training/predicting.

train_mode()

Returns a scope context to be used in ‘with’ statement in which forward pass behavior is set to training mode, without changing the recording states.

Classes

Function()

Customize differentiation in autograd.