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

Using TochMetrics for code simplification #276

Open
Borda opened this issue May 18, 2022 · 0 comments
Open

Using TochMetrics for code simplification #276

Borda opened this issue May 18, 2022 · 0 comments

Comments

@Borda
Copy link

Borda commented May 18, 2022

🛠️ Proposed Refactor

We have been developing TorchMetrics to be a general-purpose metric and some domain-specific use-cases. In many cases, we have an exact mapping to scikit-learn with verification/testing to the reference metric for its correctness. The TM includes functional as well as nn.Module versions and for the most/standard metrics, the only dependency is PyTorch (for the domain-specific metrics you need to install related extras).

Suggest a potential alternative/fix

WIth using TM metrics you may rely on the widely tested correctness (testing against gold standards in multiple OS environments and all PyTorch versions above v1.4), and later you can use nn.Module to leverage update and compute.
Moreover, the recent release v0.8 allows re-using/sharing common compute for similar as you leverage confusion matrix.

Overall if you are fine with it, we are happy to draft a PR with a suggested change to verify in place the impact.
If you have any questions, happy to follow up with me or @aniketmaurya

What I have quickly checked, all this mit_semseg.utils can be simplified with TM

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