MCPcopy Create free account
hub / github.com/TEA-Lab/TwoByTwo / __init__

Method __init__

src/shape_assembly/models/encoder/vn_layers.py:189–201  ·  view source on GitHub ↗
(self, in_channels, dim=4, normalize_frame=False, share_nonlinearity=False, negative_slope=0.2)

Source from the content-addressed store, hash-verified

187
188class VNStdFeature(nn.Module):
189 def __init__(self, in_channels, dim=4, normalize_frame=False, share_nonlinearity=False, negative_slope=0.2):
190 super(VNStdFeature, self).__init__()
191 self.dim = dim
192 self.normalize_frame = normalize_frame
193
194 self.vn1 = VNLinearLeakyReLU(in_channels, in_channels // 2, dim=dim, share_nonlinearity=share_nonlinearity,
195 negative_slope=negative_slope)
196 self.vn2 = VNLinearLeakyReLU(in_channels // 2, in_channels // 4, dim=dim, share_nonlinearity=share_nonlinearity,
197 negative_slope=negative_slope)
198 if normalize_frame:
199 self.vn_lin = nn.Linear(in_channels // 4, 2, bias=False)
200 else:
201 self.vn_lin = nn.Linear(in_channels // 4, 3, bias=False)
202
203 def forward(self, x):
204 '''

Callers

nothing calls this directly

Calls 2

VNLinearLeakyReLUClass · 0.85
__init__Method · 0.45

Tested by

no test coverage detected