-
Notifications
You must be signed in to change notification settings - Fork 638
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
Patchcore multiple test batch size is not supported. #268
Comments
should I set test_batch_size=1? |
Can you share the tree structure of your dataset please? |
data And I find too much time for "corest sampling" I want to know if there is a good way to solve this cpu calculation problem.(i use Tesla V100S-PCIE-32GB ) |
Can you set |
Yes, if you set |
preds
and target
both should have the (same) shape (N, ...), or target
should be (N, ...) and preds
should be (N, C, ...)
You are right. Much appreciate! |
Hi @samet-akcay , thanks for developing this amazing library!
Is any investigation done since then? It'd be great if you could share any info around here if any. I'm running inference over about 18000 images. Although there is still plenty of GPU memory available during inference, due to batch size 1 restriction, inference takes more than 10 hours to finish. So, it'd be great if we could set batch size more than 1. |
I have another problem after dealing with #243
That is:
ValueError: Either
preds
andtarget
both should have the (same) shape (N, ...), ortarget
should be (N, ...) andpreds
should be (N, C, ...).Epoch 0: 100%|██████████| 34/34 [09:17<00:00, 16.39s/it, loss=nan]
From:
File "/home/devadmin/haobo/anomalib_venv/lib/python3.8/site-packages/torchmetrics/utilities/checks.py", line 269, in _check_classification_inputs
case, implied_classes = _check_shape_and_type_consistency(preds, target)
File "/home/devadmin/haobo/anomalib_venv/lib/python3.8/site-packages/torchmetrics/utilities/checks.py", line 115, in
_check_shape_and_type_consistency
Then I print preds and target:
Epoch 0: 68%|████████████████Aggregating the embedding extracted from the training set. 2.13it/s, loss=nan]
Creating CoreSet Sampler via k-Center Greedy
Getting the coreset from the main embedding.
Assigning the coreset as the memory bank.
Epoch 0: 100%|█████████████████████████████████████████████████████| 34/34 [08:59<00:00, 15.85s/it, loss=nan]
preds is: tensor([1.4457])00%|███████████████████████████████████████████████| 11/11 [08:48<00:00, 48.02s/it]
target is: tensor([[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]], dtype=torch.int32)
my patchcore config.yaml is:
Thank you for your patience in reading and answering!
The text was updated successfully, but these errors were encountered: