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

fix evaluation for the case of overlapping in the same category #2558

Merged
merged 2 commits into from
Jun 22, 2022

Conversation

linjieccc
Copy link
Contributor

PR types

Bug fixes

PR changes

Others

Description

  • 修复UIE对于同类别嵌套的评估问题

    目前的评估方式会丢掉相对更长的那个实体,导致计算recall的时候Ground Truth的个数变少:

    label_set = get_span(label_start_ids, label_end_ids)
    num_label = len(label_set)

    Ground Truth的个数改为通过真实的span个数来统计:

    num_label = max(len(label_start_ids), len(label_end_ids))

Copy link
Collaborator

@wawltor wawltor left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@linjieccc linjieccc merged commit fc0313b into PaddlePaddle:develop Jun 22, 2022
@linjieccc linjieccc deleted the fix_evaluate branch June 22, 2022 12:07
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

Successfully merging this pull request may close these issues.

None yet

2 participants