Exemplo n.º 1
0
    def Abs(self, cntk_op, inputs):
        """
        Returns element-wise absolute of inputs[0].

        Arguments:
            cntk_op: CNTK operation to be imported.
            inputs: List of inputs to this node.

        Returns:
            A ngraph Op.
        """
        assert len(inputs) == 1

        return ng.absolute(inputs[0]).named(cntk_op.uid)
Exemplo n.º 2
0
def abs(x, name=None):
    return ng.absolute(x).named(name)
Exemplo n.º 3
0
def Abs(onnx_node, ng_inputs):  # type: (NodeWrapper, List[NgraphNode]) -> NgraphNode
    """Apply f(x) = abs(x) to the input tensor elementwise."""
    return ng.absolute(ng_inputs[0])
Exemplo n.º 4
0
def Abs(onnx_node, ng_inputs):  # type: (NodeWrapper, List[TensorOp]) -> Op
    return ng.absolute(ng_inputs[0])