amazon-science / patchcore-inspection

Apache License 2.0
691 stars 142 forks source link

(Resolved) Evaluation problem #64

Closed wahyurahmaniar closed 1 year ago

wahyurahmaniar commented 1 year ago

Hi, Thanks for sharing the code.

I have a problem running the evaluation. I got this error:

_pickle.UnpicklingError: invalid load key, 'v'.

Any solution? Thank you in advance.

wahyurahmaniar commented 1 year ago

I set num_workers=0 and faiss_num_workers=0 for run_patchcore.py and load_and_evaluate_patchcore.py

Ehteshamciitwah commented 1 year ago

Hello, I have the same problem while loading the pkl file how did you solve it? System: Window Environment: python 3.9 torch 1.10

wahyurahmaniar commented 1 year ago

Set the num_workers=0and faiss_num_workers=0

Ehteshamciitwah commented 1 year ago

Sorry, I did not use Git lfs during the cloning repository. If we directly download the repository, we are not able to fetch data from git lfs file. So I clone the repository using git clone and than use git lfs to fetch pre-trained weights. In this way, we can load correctly. I think there is no connection of num worker with the loading of pkl file.

wahyurahmaniar commented 1 year ago

Set the num_workers=0 in run_patchcore.py and faiss_num_workers=0 in load_and_evaluate_patchcore.py

baoyuchen commented 1 month ago

Set the num_workers=0 in run_patchcore.py and faiss_num_workers=0 in load_and_evaluate_patchcore.py Hi, I don't know why, but I'm still getting errors with this setup!