MCPcopy Create free account
hub / github.com/294coder/Dif-PAN / __init__

Method __init__

models/unet_model_google.py:97–106  ·  view source on GitHub ↗
(self, dim, dim_out, groups=32, dropout=0)

Source from the content-addressed store, hash-verified

95
96class Block(nn.Module):
97 def __init__(self, dim, dim_out, groups=32, dropout=0):
98 super().__init__()
99 self.block = nn.Sequential(
100 # nn.BatchNorm2d(dim),
101 nn.GroupNorm(groups, dim),
102 # LayerNorm2d(dim),
103 Swish(),
104 nn.Dropout(dropout) if dropout != 0 else nn.Identity(),
105 nn.Conv2d(dim, dim_out, 3, padding=1),
106 )
107
108 def forward(self, x):
109 return self.block(x)

Callers

nothing calls this directly

Calls 2

SwishClass · 0.70
__init__Method · 0.45

Tested by

no test coverage detected