VectorNorm¶
Compute a norm of the vectors represented by the given axis.
This node interprets all values along the given axis as a vector, and returns its norm. If the data has more axes, e.g., channels, then the vector length is taken separately for each channel/etc of these axes. The chosen axis will be replaced by a one-element feature axis, unless drop_axis is set. If the data is an array and no numeric axis was specified, the axis defaults to -1 (i.e., the last axis of the data). More Info... Version 1.0.0
Ports/Properties¶
data¶
Data to process.
- verbose name: Data
- default value: None
- port type: DataPort
- value type: AnyNumeric (can be None)
- data direction: INOUT
axis¶
Axis along which to take the statistic. This axis will drop out of the data and be replaced by a dummy one-element axis (of type feature). You may specify an axis with its label (i.e., space.mylabel) or in the case of incoming data that is an array instead of a Packet, the index of the axis.
- verbose name: Act Along Axis
- default value: space
- port type: ComboPort
- value type: str (can be None)
ord¶
Order of the norm. The default is 2, which corresponds to the Euclidean norm or vector length. Other values are 1 (l1 norm aka Manhattan distance), 0 (number of nonzeros), inf (maximum value), and fractional p-norms for p >= 1.
- verbose name: Order Of Norm
- default value: 2
- port type: FloatPort
- value type: float (can be None)
drop_axis¶
Drop the axis from the data.
- verbose name: Drop Axis
- default value: False
- port type: BoolPort
- value type: bool (can be None)
set_breakpoint¶
Set a breakpoint on this node. If this is enabled, your debugger (if one is attached) will trigger a breakpoint.
- verbose name: Set Breakpoint (Debug Only)
- default value: False
- port type: BoolPort
- value type: bool (can be None)
metadata¶
User-definable meta-data associated with the node. Usually reserved for technical purposes.
- verbose name: Metadata
- default value: {}
- port type: DictPort
- value type: dict (can be None)