mirror of
https://github.com/wassname/multifit.git
synced 2026-10-28 13:10:15 +08:00
Remove bidir
This commit is contained in:
1 parent
5e44e442b2
commit
5dced1e488
2 files changed
+2
-2
No files matched your search
@@ -206,7 +206,7 @@ class LMHyperParams:
|
||||
|
||||
def create_lm_learner(self, data_lm, dps=None, **kwargs):
|
||||
assert self.bidir == False, "bidirectional model is not yet supported"
|
||||
config = dict(emb_sz=self.emb_sz, n_hid=self.nh, n_layers=self.nl, pad_token=PAD_TOKEN_ID, qrnn=self.qrnn, bidir=self.bidir,
|
||||
config = dict(emb_sz=self.emb_sz, n_hid=self.nh, n_layers=self.nl, pad_token=PAD_TOKEN_ID, qrnn=self.qrnn,
|
||||
tie_weights=True, out_bias=True)
|
||||
config.update(dps or self.dps)
|
||||
trn_args = dict(clip=self.clip, alpha=self.rnn_alpha, beta=self.rnn_beta)
|
||||
|
||||
@@ -93,7 +93,7 @@ class CLSHyperParams(LMHyperParams):
|
||||
|
||||
def create_cls_learner(self, data_clas, dps=None, **kwargs):
|
||||
assert self.bidir == False, "bidirectional model is not yet supported"
|
||||
config = dict(emb_sz=self.emb_sz, n_hid=self.nh, n_layers=self.nl, pad_token=PAD_TOKEN_ID, qrnn=self.qrnn, bidir=self.bidir)
|
||||
config = dict(emb_sz=self.emb_sz, n_hid=self.nh, n_layers=self.nl, pad_token=PAD_TOKEN_ID, qrnn=self.qrnn)
|
||||
config.update(dps or self.dps)
|
||||
trn_args=dict(bptt=self.bptt, clip=self.clip)
|
||||
trn_args.update(kwargs)
|
||||
|
||||
Reference in new issue
Block a user