Comments (11)
Sure will share the overall code structure.
from torch-metrics.
I agree here. The meaning of the attributes should ideally be agnostic to the client here. IMHO, that is a good way of designing a closed solution. To rephrase, the method definition should not be dependent upon the task at hand. Since precision and recall is a very generic metric and can be used in a lot of forms, we can have this outside of all the directories and not in any of them. This way, the import would be something like this from torch_metrics import precision
. This would not create any form of confusion to the client (user) in any manner. Also, we would be providing additional documentation to support how the attributes can be used for different ML tasks.
Hope this makes sense!
from torch-metrics.
Hello @enochkan and @zutshianand, we can have a structure somewhat like this:
torch_metrics
|-- classification
| |-- accuracy.py
| |-- dice.py
| |-- f1.py
| |-- hinge.py
| |-- kldivergence.py
| |-- pr.py
| `-- squarehinge.py
|-- object_detection
| |-- average_precision.py
| `-- precision_recall_curve.py
|-- regression
| |-- logcosh.py
| |-- mae.py
| |-- meaniou.py
| |-- mse.py
| |-- rmse.py
| `-- rsquared.py
`-- utils.py
What do you guys think?
from torch-metrics.
that looks great. I appreciate the effort. I can keep a running bullet list of what's implemented and what needs to be done in the Readme file.
from torch-metrics.
We can essentially have two directories for Classification and Regression. AFAIK, Image segmentation is also a classification task, hence it should ideally be in Classification. Also, I think KL Divergence is mostly used in classification tasks since we deal with probabilities and their distributions in classification tasks. So we can essentially divide most of the metrics as classification or regression.
You can add a list of metrics which you feel do not fit either in classification or regression and we can decide then.
Also, in this, do we really need an object-detection directory as well? Precision and recall can come under classification right? What do you think?
from torch-metrics.
Sure @zutshianand, will create that list.
Based on this comment by @Vijayabhaskar96, I created it like that. But surely we can modify it.
from torch-metrics.
That's a great suggestion. Do you mind coming up with a list of function methods? I'm quite busy at the moment, otherwise I can get to it in a couple days. 👍
from torch-metrics.
@hassiahk @zutshianand can you guys also think of ways to make this package more popular? I'm loving the feedbacks and contributions from both of you, and would love it for more people to use it haha.
from torch-metrics.
@enochkan Right now I can only think of these:
- Better README.md with examples to all the available metrics and different ways they can be used.
- Example notebooks on how to implement these metrics in real word problems like how they have it in TensorFlow. This will take a lot of time though and we can probably ignore for now.
- Add more metrics and functionalities to each metric.
- Lastly to share it among social circles and ask for feedback.
These ideas just came from top of my head, so I will share some more ideas if I come across any, by raising new issues.
from torch-metrics.
@enochkan @zutshianand Some of the metrics cannot be classified as either Classification
or Regression
like DSC (Dice Similarity Coefficient)
which is mainly used for Image Segmentation
(For this, we can create a new folder) and some of the metrics can be used in both Classification
and Regression
like KL Divergence
. What should we do in such cases? How to structure these metrics?
from torch-metrics.
Precision and recall formula for both classification and object detection is the same but the problem is how the TP, FP, TN, and FN are calculated. If the Precision is made to take TP and FP as input instead of directly taking target and predicted tables as input, the same function can be used to calculate both Object detection and classification, but that would make the user experience bad.
from torch-metrics.
Related Issues (17)
- New metrics that are not in the README.md HOT 1
- Tests for metrics HOT 11
- Tool for Documentation HOT 10
- List of metrics and Initial refactor
- Code Linting HOT 3
- Tests for MSLE HOT 2
- aupr metric needed HOT 2
- Library "ImportError" - Missing packages in setup.py HOT 2
- NLP Metrics HOT 1
- Vision Metrics HOT 1
- bug when importing: "cannot import name 'classification' from partially initialized module 'torch_metrics'" HOT 2
- Circular Import HOT 5
- Code formatting and docstrings for all functions HOT 4
- Client specific errors HOT 5
- Exhaustive list of metrics HOT 10
- Regarding Object detection metrics HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from torch-metrics.