allenai / allenai/sequential_sentence_classification

Prediction with CRF for true test data

未关闭
#12 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
主要语言
Python
星标
77
派生
28
PR 合并指标
30 天内没有已合并 PR

描述

Hi,

Thank you for sharing the code for your work. I have been able to run the code and train the models for all the three cases. When I try to run predictor.py, it works fine for BERT and (BERT + Transformer) models. However, when using predictor.py for a (BERT + Transformer + CRF) model, since we don't have true labels for test data, the below code gives error:

` if self.with_crf:

mask_sentences = (labels != -1)

best_paths = self.crf.viterbi_tags(label_logits, mask_sentences)`

I understand why it gives an error, but was not sure how or what to modify in order for it to work.

Any suggestion will be really helpful.

Thank you!

贡献指南

这个仓库没有索引到贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。