stopGradient(for:)
Adds the tensors that you specify, to indicate which contributions the graph excludes when computing gradients during gradient pass.
Declaration
func stopGradient(for tensors: [MLCTensor]) -> BoolParameters
- tensors:
An array that contains the tensors whose contributions the graph excludes.
Return Value
true if the operation was successful.