提交 97d92993 编写于 作者: K kinghuin 提交者: wuzewu

fix seq predict bug (#294)

上级 c08eccd5
......@@ -232,6 +232,6 @@ class SequenceLabelTask(BaseTask):
for length in seq_lens:
seq_infers = batch_infers[current_id:current_id + length]
seq_result = list(map(id2label.get, seq_infers[1:-1]))
current_id += self.max_seq_len
current_id += length if self.add_crf else self.max_seq_len
results.append(seq_result)
return results
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册