Giter VIP home page Giter VIP logo

metric4coref's Introduction

Hi there ๐Ÿ‘‹

๐ŸŒฑ Iโ€™m currently learning AI

LowinLi's GitHub stats


Baidu Azure Microsoft Learn ChatGPT Python PyTorch Pandas FastAPI JavaScript Vue.js Quasar Angular Kubernetes GitLab CI GitHub Actions Visual Studio Code Jupyter Notebook Markdown LaTeX Switch Firefox

Rss

metric4coref's People

Contributors

lowinli avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

cooper12121

metric4coref's Issues

F1 score error

Hi, thank you for this great tool and the elaborated explanation of those metrics. :)

Just a kind reminder that in the calculation of f1, it is possible for both precision and recall to be zero and thus it might give an error as the denominator might be zero. The same for precision and recall, too.

Many thanks again!

Problem in b_cubed calculation

Hi again, I rechecked the code and I found there was a tiny problem. After summing up all the precisions and recalls of all mentions, the value should be normalized by the number of mentions either in the predicted clusters (for precision) or in the gold clusters (for recall), but you the number you used is simply the number of the intersection between two clusters, which makes the denominator incorrect.

Regarding the MUC, I commented on another closed issue.

Hope it makes sense. :)

Issue with shuffling cluster order in MUC

Hello

Thanks so much for making this available in python - it's really useful!

I think there might be a bit of a problem with the MUC measure - it gives different results depending on the order of the cluster elements.

For example:

predict_clusters = [["a", "b", "c"], ["d", "e", "f", "g"], ["h", "i", "j"], ["k"]]
predict_clusters_shuffled = [["c", "b", "a"], ["e", "d", "g", "f"], ["j", "i", "h"], ["k"]]
gold_clusters = [["a", "b", "d"], ["c", "e", "f", "g"], ["h", "i", "j", "k"]]

print(metric4coref.muc(predict_clusters, gold_clusters))
>>> (0.5833333333333334, 0.4666666666666667, 0.5185185185185186)

print(metric4coref.muc(predict_clusters_shuffled, gold_clusters))
>>> (0.16666666666666666, 0.13333333333333333, 0.14814814814814814)

This doesn't seem to be a problem with any of the other measures.

For now, I'm just sorting all my clusters before I evaluate them, but I just wanted to flag!

Thanks,
Emily

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.