Python class
Value
Value
class max.graph.Value(value: Value | Value | TensorValue | Weight | Shape | Dim | int | float | integer | floating | ndarray)
Represents a symbolic value within a Graph.
A Value can represent the output of a node, the arguments of a Graph (as seen from within its body), and more generally any symbolic value available within the Graph. Other nodes receive Value values as inputs to form a computation graph.
A Value may also refer to an existing input or output of a node, and you can change them, such as by swapping a new Value.
Conceptually, think of a Value as an edge in the dataflow graph, with the other end being the user of that value.
Similar to a regular variable, a Value has a data type.
opaque
property opaque*: _OpaqueValue*
Returns the Value as an _OpaqueValue
.
Raises an exception if the Value is not a _OpaqueValue.
tensor
property tensor*: TensorValue*
Returns the Value as a TensorValue
.
Raises an exception if the Value is not a TensorValue.
Was this page helpful?
Thank you! We'll create more content like this.
Thank you for helping us improve!