Skip to content

Commit a5c78a5

Browse files
fix bug
1 parent f2279fa commit a5c78a5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

extractnet/nn_models.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ def decode_output(self, logits, doc_blocks):
6969
top_k = 10
7070
scores = softmax([preds[:, idx]])[0]
7171
ind = np.argpartition(preds[:, idx], -top_k)[-top_k:]
72-
result = [ (fix_encoding(str_cast(blocks[idx].text), scores[idx])) for idx in ind if scores[idx] > self.cls_threshold]
72+
result = [ (fix_encoding(str_cast(blocks[idx].text)), scores[idx]) for idx in ind if scores[idx] > self.cls_threshold]
7373
# sort values by confidence
7474
output[label] = sorted(result, key=lambda x:x[1], reverse=True)
7575
else:

0 commit comments

Comments
 (0)