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

I encountered an error while evaluating #37

Open
zty292 opened this issue Mar 27, 2024 · 1 comment
Open

I encountered an error while evaluating #37

zty292 opened this issue Mar 27, 2024 · 1 comment

Comments

@zty292
Copy link

zty292 commented Mar 27, 2024

(EfficientAD) E:\PycharmProjects\EfficientAD-main>python mvtec_ad_evaluation/evaluate_experiment.py --dataset_base_dir E:\Dataset\anomaly_detection\mvtec_anomaly_detection\mvtec_anomaly_detection\ --anomaly_maps_dir E:\PycharmProjects\EfficientAD-main\output\1\anomaly_maps\mvtec_ad --output_dir E:\PycharmProjects\EfficientAD-main\output\1\metrics/mvtec_ad --
evaluated_objects bottle
=== Evaluate bottle ===
Parsed 83 ground truth image files.
Read ground truth files and corresponding predictions...
0%| | 0/83 [00:00<?, ?it/s]
Traceback (most recent call last):
File "E:\PycharmProjects\EfficientAD-main\mvtec_ad_evaluation\evaluate_experiment.py", line 247, in
main()
File "E:\PycharmProjects\EfficientAD-main\mvtec_ad_evaluation\evaluate_experiment.py", line 215, in main
calculate_au_pro_au_roc(
File "E:\PycharmProjects\EfficientAD-main\mvtec_ad_evaluation\evaluate_experiment.py", line 148, in calculate_au_pro_au_roc
prediction = util.read_tiff(pred_name)
File "E:\PycharmProjects\EfficientAD-main\mvtec_ad_evaluation\generic_util.py", line 105, in read_tiff
raise IOError('Found multiple files with a TIFF extension at'
OSError: Found multiple files with a TIFF extension at E:\PycharmProjects\EfficientAD-main\output\1\anomaly_maps\mvtec_ad\bottle\test\broken_large\000
Please specify which TIFF extension to use via the exts parameter of this function.

@HoseinHashemi
Copy link

HoseinHashemi commented May 15, 2024

Pass the argument exts=['.tiff'] to the util.read_tiff(pred_name) and it must solve the issue.
So line 148 of evaluate_experiment.py should look like : prediction = util.read_tiff(pred_name, exts=['.tiff'])

Or alternatively, the function could be changed to deal with the issue.

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