MCPcopy Create free account
hub / github.com/WarmCongee/SDUMC / forward

Method forward

toolkit/models/modules/encoder.py:30–41  ·  view source on GitHub ↗

Args: x: tensor of shape (batch_size, in_size)

(self, x)

Source from the content-addressed store, hash-verified

28 self.linear_3 = nn.Linear(hidden_size, hidden_size)
29
30 def forward(self, x):
31 '''
32 Args:
33 x: tensor of shape (batch_size, in_size)
34 '''
35 # normed = self.norm(x)
36 dropped = self.drop(x)
37 y_1 = F.relu(self.linear_1(dropped))
38 y_2 = F.relu(self.linear_2(y_1))
39 y_3 = F.relu(self.linear_3(y_2))
40
41 return y_3
42
43
44# TFN 中的文本编码,额外需要lstm 操作 [感觉是audio|video]

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected