braindecode.modules.AvgPool2dWithConv#

class braindecode.modules.AvgPool2dWithConv(kernel_size, stride, dilation=1, padding=0)[source]#

Compute average pooling using a convolution, to have the dilation parameter.

Parameters:
  • kernel_size ((int,int)) – Size of the pooling region.

  • stride ((int,int)) – Stride of the pooling operation.

  • dilation (int or (int,int)) – Dilation applied to the pooling filter.

  • padding (int or (int,int)) – Padding applied before the pooling operation.

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.