Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

code疑问:BertModel的传参和distill中teacher的预测输入 #9

Open
Daishijun opened this issue Oct 21, 2020 · 0 comments
Open

Comments

@Daishijun
Copy link

Daishijun commented Oct 21, 2020

sequence_output, _ = self.bert(input_ids, None, input_mask, output_all_encoded_layers=False)
这里的传参,input_mask是不是传错位置了,您这样相当于attention_mask是None, token_type_ids是input_mask。
https://github.com/qiangsiwei/bert_distill/blob/master/distill.py#L22 这里预测的时候为什么不加[CLS]和[SEP]了?
感谢大佬开源,希望大佬能解答下我的疑惑。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant