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

Get final result with new test image #15

Open
NguyenHongSon1103 opened this issue Dec 2, 2021 · 3 comments
Open

Get final result with new test image #15

NguyenHongSon1103 opened this issue Dec 2, 2021 · 3 comments

Comments

@NguyenHongSon1103
Copy link

Hi,
I am confusing about how to determine if an image is anomalous or not because model has two output: classification prediction and GDE scores.
Should I use a threshold for GDE scores to check and ignore model prediction ?
Thank you for your work and your reply :)

@Runinho
Copy link
Owner

Runinho commented Dec 2, 2021

Should I use a threshold for GDE scores to check and ignore model prediction ?

Yes, during inference/validation the paper uses the Density Estimation to detect anomalous data.
The Model is used as a feature extractor on which the density estimation is performed.

During training the whole model, the part that is used as a feature extractor plus a model head, is trained on the cutpast classification proxy task. So the classification output is only used as a proxy task to train the model.

@NguyenHongSon1103
Copy link
Author

can you please tell me how to calculate that threshold, i don't see it in your code.

@Runinho
Copy link
Owner

Runinho commented Dec 4, 2021

can you please tell me how to calculate that threshold, i don't see it in your code.

I answered a similar question here:
The thresholding in the evaluation is done by calculating the roc. This might be an option for your implementation (See ROC on wikipedia).

Another Paper by Ripple et al. which Li et. al reference use a probabilistic perspective of calculating thresholds: https://github.com/ORippler/gaussian-ad-mvtec/blob/a2e15800f0087fc7b965e491c53a73f8c7480d1e/src/gaussian/model.py#L152

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

2 participants