Method
__init__
(self, channels, use_conv, dims=2, out_channels=None)
Source from the content-addressed store, hash-verified
| 160 | """ |
| 161 | |
| 162 | def __init__(self, channels, use_conv, dims=2, out_channels=None): |
| 163 | super().__init__() |
| 164 | self.channels = channels |
| 165 | self.out_channels = out_channels or channels |
| 166 | self.use_conv = use_conv |
| 167 | self.dims = dims |
| 168 | if use_conv: |
| 169 | self.conv = conv_nd(dims, self.channels, self.out_channels, 3, padding=1) |
| 170 | |
| 171 | def forward(self, x): |
| 172 | assert x.shape[1] == self.channels |
Callers
nothing calls this directly
Tested by
no test coverage detected