感谢大佬的开源,我想请教下MTMSN/squad/squad_utils.py 中
for token in query_tokens:
token_positions.append(len(tokens))
tokens.append(token)
segment_ids.append(0)
if token in sub_doc_tokens and token not in stop_words:
em_mask.append(1)
else:
em_mask.append(0)
tokens.append("[SEP]")
segment_ids.append(0)
em_mask.append(0)
这块的EM特征在BERT模型中如何使用?在BERT Embedding之后如何结合sequence_output 使用呢?看到您并未使用这个文件,谢谢您的解答~
def forward(self, input_ids, token_type_ids, attention_mask, start_positions=None, end_positions=None):
all_encoder_layers, _ = self.bert(input_ids, token_type_ids, attention_mask)
sequence_output = all_encoder_layers[-1]
感谢大佬的开源,我想请教下MTMSN/squad/squad_utils.py 中
这块的EM特征在BERT模型中如何使用?在BERT Embedding之后如何结合sequence_output 使用呢?看到您并未使用这个文件,谢谢您的解答~