Deep learning for NeuroImaging in Python.
Note
This page is a reference documentation. It only explains the class signature, and not how to use it. Please refer to the gallery for the big picture.
- class surfify.nn.modules.IcoSpMaConv(in_feats, out_feats, kernel_size, stride=1, pad=0)[source]¶
Define the convolutional layer on icosahedron discretized sphere using spherical 2-d mapping & circular padding.
See also
Notes
Debuging messages can be displayed by changing the log level using
setup_logging(level='debug')
.Examples
>>> import torch >>> from surfify.nn import IcoSpMaConv >>> module = IcoSpMaConv( in_feats=8, out_feats=16, kernel_size=3, stride=2, pad=1) >>> proj_ico_x = torch.zeros((10, 8, 194, 194)) >>> proj_ico_x = module(proj_ico_x) >>> proj_ico_x.shape
Init IcoSpMaConv.
- Parameters:
in_feats : int
input features/channels.
out_feats : int
output features/channels.
kernel_size : int or tuple
the convolutional kernel size.
stride : int or tuple, default 1
controls the stride for the cross-correlation.
pad : int or tuple (pad_azimuth, pad_elevation), default 0
the size of the padding.
- 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.
Follow us