rvorias / ind_knn_ad

Vanilla torch and timm industrial knn-based anomaly detection for images.
https://share.streamlit.io/rvorias/ind_knn_ad
MIT License
147 stars 50 forks source link

Training strategy for each class?! #16

Closed Mshz2 closed 3 years ago

Mshz2 commented 3 years ago

Hi! In your custom dataset guideline, you put all good samples into one folder. In my custom dataset, I have three class of objects. I was wondering does it make sense if I train the padim for individual classes and do inference for each class with their seperate models? or it is also ok if I put all classes into one bag of good samples and have one model for all? I really appreciate your suggestions based on your experience.

Best

rvorias commented 3 years ago

Hey thanks for your question.

Because of the way these models work, I'd say it's safer to keep each class separate. However, there are some considerations:

Hope that sheds some light on your question.