MCPcopy Create free account
hub / github.com/cure-lab/deep-active-learning / __init__

Method __init__

models/linear.py:9–12  ·  view source on GitHub ↗
(self, dim, n_class)

Source from the content-addressed store, hash-verified

7
8class linMod(nn.Module):
9 def __init__(self, dim, n_class):
10 super(linMod, self).__init__()
11 self.dim = dim
12 self.lm = nn.Linear(int(np.prod(dim)), n_class)
13 def forward(self, x):
14 x = x.view(-1, int(np.prod(self.dim)))
15 out = self.lm(x)

Callers

nothing calls this directly

Calls 1

__init__Method · 0.45

Tested by

no test coverage detected