neuroprob/filters.py
def forward(self, input, stimulus=None):
        """
        Introduces the spike coupling by convolution with the spike train, no padding and left removal 
        for causal convolutions.
        
        :param torch.tensor input: input spiketrain or covariates with shape (trials, neurons, timesteps) 
                                   or (samples, neurons, timesteps)
        :returns: filtered input of shape (trials, neurons, timesteps)
        """
        h_, v_ = self.compute_filter()
        mean_conv = F.conv1d(input, h_, groups=self.conv_groups)
        
        if isinstance(v_, Number) is False:
            var_conv = F.conv1d(input, v_, groups=self.conv_groups)
        else:
            var_conv = 0
            
        return mean_conv, var_conv

        Introduces the spike coupling by convolution with the spike train, no padding and left removal 
        for causal convolutions.
        
        :param torch.tensor input: input spiketrain or covariates with shape (trials, neurons, timesteps) 
                                   or (samples, neurons, timesteps)
        :returns: filtered input of shape (trials, neurons, timesteps)
        
Introduces the spike coupling by convolution with the spike train, no padding and left removal
for causal convolutions.
Introduces the spike coupling by convolution with the spike train no padding and left removal for causal convolutions .
def forward(self, input, stimulus=None):
        h_, v_ = self.compute_filter()
        mean_conv = F.conv1d(input, h_, groups=self.conv_groups)
        if isinstance(v_, Number) is False:
            var_conv = F.conv1d(input, v_, groups=self.conv_groups)
        else:
            var_conv = 0
        return mean_conv, var_conv
def forward ( self , input , stimulus = None ) : h_ , v_ = self . compute_filter ( ) mean_conv = F . conv1d ( input , h_ , groups = self . conv_groups ) if isinstance ( v_ , Number ) is False : var_conv = F . conv1d ( input , v_ , groups = self . conv_groups ) else : var_conv = 0 return mean_conv , var_conv
Introduces the spike coupling by convolution with the spike train, no padding and left removal
for causal convolutions.
Introduces the spike coupling by convolution with the spike train no padding and left removal for causal convolutions .
"""
        Introduces the spike coupling by convolution with the spike train, no padding and left removal 
        for causal convolutions.
        
        :param torch.tensor input: input spiketrain or covariates with shape (trials, neurons, timesteps) 
                                   or (samples, neurons, timesteps)
        :returns: filtered input of shape (trials, neurons, timesteps)
        """
filtered input of shape (trials, neurons, timesteps)
filtered input of shape ( trials neurons timesteps )
self
input
input spiketrain or covariates with shape (trials, neurons, timesteps)
or (samples, neurons, timesteps)
input spiketrain or covariates with shape ( trials neurons timesteps ) or ( samples neurons timesteps )
stimulus