nip.utils.torch.MaxPool2dSimulateBatchDims#
- class nip.utils.torch.MaxPool2dSimulateBatchDims(kernel_size: int | Tuple[int, ...], stride: int | Tuple[int, ...] | None = None, padding: int | Tuple[int, ...] = 0, dilation: int | Tuple[int, ...] = 1, return_indices: bool = False, ceil_mode: bool = False)[source]#
2D max pool layer with arbitrary batch dimensions.
See
torch.nn.MaxPool2d
for documentation.Assumes an input of shape (… channels height width).
Methods Summary
forward
(x)Apply the module to the input tensor, simulating multiple batch dimensions.
Attributes
T_destination
call_super_init
dump_patches
feature_dims
kernel_size
stride
padding
dilation
return_indices
ceil_mode
training
Methods