Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

true_which_overlapped_with_pred does not get updated properly #17

Open
amobash2 opened this issue Jun 8, 2020 · 0 comments
Open

true_which_overlapped_with_pred does not get updated properly #17

amobash2 opened this issue Jun 8, 2020 · 0 comments

Comments

@amobash2
Copy link

amobash2 commented Jun 8, 2020

Hi,

I think there are few scenarios that you are not updating true_which_overlapped_with_pred properly, and break your for loops.

For example in line 267 of ner_eval.py file, you are appending a "true" entity to true_which_overlapped_with_pred. and then set found_overlap = True and then break. In this case you are not appending other "true" entities that they have partial overlap. For example if annotated data has two spans of [2,4] and [5, 7] and NER model has one span of [3, 6], both "true" spans have overlap with this one "pred" span, but you are breaking the loop, before allowing appending of entity with span [5, 7] to be added to the true_which_overlapped_with_pred. I think it is right that metrics should not get updated, but true_which_overlapped_with_pred should get updated with both "true" spans.

I tried changing the code as follows and it started counting spans properly:

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant