def __init__(self, operator):
        """Initialize a new instance.

        Parameters
        ----------
        operator : `Operator`
            The ODL operator to be wrapped. For gradient computations to
            work, ``operator.derivative(x).adjoint`` must be implemented.

        Examples
        --------
        >>> matrix = np.array([[1, 0, 1],
        ...                    [0, 1, 1]], dtype='float32')
        >>> odl_op = odl.MatrixOperator(matrix)
        >>> torch_op = OperatorAsModule(odl_op)
        >>> torch_op.op_func.operator is odl_op
        True
        """
        super(OperatorAsModule, self).__init__()
        self.op_func = OperatorAsAutogradFunction(operator)
def __init__ ( self , operator ) : super ( OperatorAsModule , self ) . __init__ ( ) self . op_func = OperatorAsAutogradFunction ( operator )
Initialize a new instance.

        Parameters
        ----------
        operator : `Operator`
            The ODL operator to be wrapped. For gradient computations to
            work, ``operator.derivative(x).adjoint`` must be implemented.

        Examples
        --------
        >>> matrix = np.array([[1, 0, 1],
        ...                    [0, 1, 1]], dtype='float32')
        >>> odl_op = odl.MatrixOperator(matrix)
        >>> torch_op = OperatorAsModule(odl_op)
        >>> torch_op.op_func.operator is odl_op
        True