bi-att-flow
bi-att-flow copied to clipboard
Predict empty answer with high score
When predicting answer, sometimes I get empty answer, however the score is high enough.
Finally I locate the problem. A function called _get2
at line 284 and 382 in file basic/evaluator.py
, the judgement if len(xi[span[0][0]]) <= span[1][1]:
should be if len(xi[span[0][0]]) < span[1][1]:
.
When the stop position is at the end of context
, span[1][1]
is equal with len(xi[span[0][0]])
.