value R6 class
value.Rdvalue R6 class
value R6 class
Details
Represents a node in the computational graph with automatic differentiation. Each value object holds data, gradient, a backward function, previous nodes, and an optional label for debugging.
Public fields
dataNumeric value of the object
gradGradient value, initially set to 0
backward_fnA function that performs the backward pass (gradient computation)
prevA list of previous nodes in the computational graph
labelOptional character label for debugging (default: "")