neuroprob/filters.py
def compute_filter(self, stim):
        """
        The sample dimension is the label index for all nonzero spike bins.
        
        :param torch.tensor stim: the stimulus variable at all nonzero bins of shape (samples, timestep, dims), note 
                                  the sample dimension includes the MC samples as well as the history shifts (KxT)
        :returns: filter mean of shape (samples, n_out, n_in, timesteps), filter variance of same shape
        :rtype: tuple of torch.tensor
        """
        cov = torch.cat((self.cov.expand(stim.shape[0], *self.cov.shape[1:]), stim), dim=-1) # sample x timesteps x dims
        F_mu, F_var = self.filter_model.compute_F(cov) # samples, neurons, timesteps
        if isinstance(F_var, Number) is False:
            F_var = F_var.view(stim.shape[0], self.out_dim, self.in_dim, -1)
        return F_mu.view(stim.shape[0], self.out_dim, self.in_dim, -1), F_var

        The sample dimension is the label index for all nonzero spike bins.
        
        :param torch.tensor stim: the stimulus variable at all nonzero bins of shape (samples, timestep, dims), note 
                                  the sample dimension includes the MC samples as well as the history shifts (KxT)
        :returns: filter mean of shape (samples, n_out, n_in, timesteps), filter variance of same shape
        :rtype: tuple of torch.tensor
        
The sample dimension is the label index for all nonzero spike bins.
The sample dimension is the label index for all nonzero spike bins .
def compute_filter(self, stim):
        cov = torch.cat((self.cov.expand(stim.shape[0], *self.cov.shape[1:]), stim), dim=-1) 
        F_mu, F_var = self.filter_model.compute_F(cov) 
        if isinstance(F_var, Number) is False:
            F_var = F_var.view(stim.shape[0], self.out_dim, self.in_dim, -1)
        return F_mu.view(stim.shape[0], self.out_dim, self.in_dim, -1), F_var
def compute_filter ( self , stim ) : cov = torch . cat ( ( self . cov . expand ( stim . shape [ 0 ] , * self . cov . shape [ 1 : ] ) , stim ) , dim = - 1 ) F_mu , F_var = self . filter_model . compute_F ( cov ) if isinstance ( F_var , Number ) is False : F_var = F_var . view ( stim . shape [ 0 ] , self . out_dim , self . in_dim , - 1 ) return F_mu . view ( stim . shape [ 0 ] , self . out_dim , self . in_dim , - 1 ) , F_var
The sample dimension is the label index for all nonzero spike bins.
The sample dimension is the label index for all nonzero spike bins .
"""
        The sample dimension is the label index for all nonzero spike bins.
        
        :param torch.tensor stim: the stimulus variable at all nonzero bins of shape (samples, timestep, dims), note 
                                  the sample dimension includes the MC samples as well as the history shifts (KxT)
        :returns: filter mean of shape (samples, n_out, n_in, timesteps), filter variance of same shape
        :rtype: tuple of torch.tensor
        """ # sample x timesteps x dims # samples, neurons, timesteps
filter mean of shape (samples, n_out, n_in, timesteps), filter variance of same shape
filter mean of shape ( samples n_out n_in timesteps ) filter variance of same shape
tuple of torch.tensor
self
stim
the stimulus variable at all nonzero bins of shape (samples, timestep, dims), note
the sample dimension includes the MC samples as well as the history shifts (KxT)
the stimulus variable at all nonzero bins of shape ( samples timestep dims ) note the sample dimension includes the MC samples as well as the history shifts ( KxT )