ngraph.opset2.squared_difference

ngraph.opset2.squared_difference(x1: Union[_pyngraph.Node, int, float, numpy.ndarray], x2: Union[_pyngraph.Node, int, float, numpy.ndarray], auto_broadcast: str = 'NUMPY', name: Optional[str] = None) _pyngraph.Node

Perform an element-wise squared difference between two tensors.

..math:: y[i] = (x_1[i] - x_2[i])^2

Parameters
  • x1 – The node with first input tensor.

  • x2 – The node with second input tensor.

  • auto_broadcast – The type of broadcasting that specifies mapping of input tensor axes to output shape axes. Range of values: numpy, explicit.

  • name – Optional new name for output node.

Returns

The new node performing a squared difference between two tensors.