Bert-BiLSTM-CRF-pytorch icon indicating copy to clipboard operation
Bert-BiLSTM-CRF-pytorch copied to clipboard

感觉_score_sentence方法错了

Open xiaomingtx6 opened this issue 3 years ago • 0 comments

score = score +
batch_transitions.gather(-1, (label_ids[:, t] * self.tagset_size + label_ids[:, t - 1]).view(-1, 1))
+ feats[:, t].gather(-1, label_ids[:, t].view(-1, 1)).view(-1, 1) 是否应该变为 score = score +
batch_transitions.gather(-1, (label_ids[:, t-1] * self.tagset_size + label_ids[:, t ]).view(-1, 1))
+ feats[:, t].gather(-1, label_ids[:, t].view(-1, 1)).view(-1, 1) 真实分数不应该是前一个到后一个的lable的分数吗 是不是做反了

xiaomingtx6 avatar May 11 '22 08:05 xiaomingtx6