mirror of
https://github.com/wassname/Castor.git
synced 2026-09-17 11:50:09 +08:00
committed by
Ralph Tang
parent
addc4506d1
commit
97bdaec5bb
+1
-1
@@ -48,7 +48,7 @@ class XmlCNN(nn.Module):
|
||||
|
||||
|
||||
|
||||
def forward(self, x):
|
||||
def forward(self, x, **kwargs):
|
||||
if self.mode == 'rand':
|
||||
word_input = self.embed(x) # (batch, sent_len, embed_dim)
|
||||
x = word_input.unsqueeze(1) # (batch, channel_input, sent_len, embed_dim)
|
||||
|
||||
Reference in New Issue
Block a user