PaDiM-Anomaly-Detection-Localization-master icon indicating copy to clipboard operation
PaDiM-Anomaly-Detection-Localization-master copied to clipboard

when i test,the time is so long

Open leolv131 opened this issue 3 years ago • 4 comments

when i test some images, whatever the number of images is 1 or 100,the time spent is so long. I want to know whether it is nomal

leolv131 avatar Dec 29 '21 07:12 leolv131

No, it is not normal,

DeepKnowledge1 avatar Dec 29 '21 09:12 DeepKnowledge1

No, it is not normal, i find the time is spent follow the code, my H*W is 4096,it has to loop 4096 times, is it normal? for i in range(H * W): mean = train_outputs[0][:, i] conv_inv = np.linalg.inv(train_outputs[1][:, :, i]) dist = [mahalanobis(sample[:, i], mean, conv_inv) for sample in embedding_vectors] dist_list.append(dist)

leolv131 avatar Dec 30 '21 02:12 leolv131

Yes, please have a look on the Inference time issue

https://github.com/xiahaifeng1995/PaDiM-Anomaly-Detection-Localization-master/issues/8#issuecomment-1002495651

DeepKnowledge1 avatar Dec 30 '21 13:12 DeepKnowledge1

Read the whole issue

DeepKnowledge1 avatar Dec 30 '21 13:12 DeepKnowledge1