braindecode.modules.CausalConv1d#
- class braindecode.modules.CausalConv1d(in_channels, out_channels, kernel_size, dilation=1, **kwargs)[source]#
Causal 1-dimensional convolution
Code modified from [1] and [2].
- Parameters:
in_channels (int) – Input channels.
out_channels (int) – Output channels (number of filters).
kernel_size (int) – Kernel size.
dilation (int, optional) – Dilation (number of elements to skip within kernel multiplication). Default to 1.
**kwargs – Other keyword arguments to pass to torch.nn.Conv1d, except for padding!!
References
Methods
- forward(X)[source]#
Define the computation performed at every call.
Should be overridden by all subclasses.
Note
Although the recipe for forward pass needs to be defined within this function, one should call the
Module
instance afterwards instead of this since the former takes care of running the registered hooks while the latter silently ignores them.