carpet/lista_base.py
def transform_to_u(self, x, lbda, output_layer=None):
        """Compute the output in primal analysis from given x and lbda

        Parameters
        ----------
        x : ndarray, shape (n_samples, n_dim)
            input of the network.
        lbda: float
            Regularization level for the optimization problem.
        output_layer : int (default: None)
            Layer to output from. It should be smaller than the number of
            layers of the network. If set to None, output the last layer of the
            network
        """
        output = self.transform(x, lbda, output_layer=None)
        if self._output == 'u-analysis':
            return output
        if self._output == 'z-synthesis':
            return np.cumsum(output, axis=-1)

        assert self._output == 'v-analysis_dual'
        return v_to_u(output, x, lbda, A=self.A, D=self.D)
Compute the output in primal analysis from given x and lbda

        Parameters
        ----------
        x : ndarray, shape (n_samples, n_dim)
            input of the network.
        lbda: float
            Regularization level for the optimization problem.
        output_layer : int (default: None)
            Layer to output from. It should be smaller than the number of
            layers of the network. If set to None, output the last layer of the
            network
        
Compute the output in primal analysis from given x and lbda
Parameters

x : ndarray, shape (n_samples, n_dim)
input of the network.
lbda: float
Regularization level for the optimization problem.
output_layer : int (default: None)
Layer to output from. It should be smaller than the number of
layers of the network. If set to None, output the last layer of the
network
Compute the output in primal analysis from given x and lbda Parameters x : ndarray shape ( n_samples n_dim ) input of the network . lbda : float Regularization level for the optimization problem . output_layer : int ( default : None ) Layer to output from . It should be smaller than the number of layers of the network . If set to None output the last layer of the network
def transform_to_u(self, x, lbda, output_layer=None):
        output = self.transform(x, lbda, output_layer=None)
        if self._output == 'u-analysis':
            return output
        if self._output == 'z-synthesis':
            return np.cumsum(output, axis=-1)
        assert self._output == 'v-analysis_dual'
        return v_to_u(output, x, lbda, A=self.A, D=self.D)
def transform_to_u ( self , x , lbda , output_layer = None ) : output = self . transform ( x , lbda , output_layer = None ) if self . _output == 'u-analysis' : return output if self . _output == 'z-synthesis' : return np . cumsum ( output , axis = - 1 ) assert self . _output == 'v-analysis_dual' return v_to_u ( output , x , lbda , A = self . A , D = self . D )
Compute the output in primal analysis from given x and lbda
Parameters
Compute the output in primal analysis from given x and lbda Parameters
"""Compute the output in primal analysis from given x and lbda

        Parameters
        ----------
        x : ndarray, shape (n_samples, n_dim)
            input of the network.
        lbda: float
            Regularization level for the optimization problem.
        output_layer : int (default: None)
            Layer to output from. It should be smaller than the number of
            layers of the network. If set to None, output the last layer of the
            network
        """
self
x
lbda
output_layer