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

CUDA memory increasing when runing eval.py #44

Closed
StrongerzZ opened this issue Mar 25, 2020 · 1 comment
Closed

CUDA memory increasing when runing eval.py #44

StrongerzZ opened this issue Mar 25, 2020 · 1 comment

Comments

@StrongerzZ
Copy link

StrongerzZ commented Mar 25, 2020

Batch size = 2
13667*2 images

D:\Anaconda3\envs\pytorch_envs\python.exe E:/NNDL_pytorch/SSD/eval.py
Evaluating: 1%| | 121/13667 [06:05<18:15:33, 4.85s/it]Traceback (most recent call last):
File "E:/NNDL_pytorch/SSD/eval.py", line 117, in
evaluate(test_loader, model)
File "E:/NNDL_pytorch/SSD/eval.py", line 92, in evaluate
top_k=200)
File "E:\NNDL_pytorch\SSD\detect_modules.py", line 74, in detect_objects
overlap = find_jaccard_overlap(class_decoded_locs, class_decoded_locs) # (n_qualified, n_qualified)
File "E:\NNDL_pytorch\SSD\utils.py", line 697, in find_jaccard_overlap
intersection = find_intersection(set_1, set_2) # (n1, n2)
File "E:\NNDL_pytorch\SSD\utils.py", line 681, in find_intersection
intersection_dims = torch.clamp(upper_bounds - lower_bounds, min=0) # (n1, n2, 2)
RuntimeError: CUDA out of memory. Tried to allocate 776.00 MiB (GPU 0; 8.00 GiB total capacity; 2.90 GiB already allocated; 32.01 MiB free; 604.85 MiB cached)
Evaluating: 1%| | 121/13667 [06:07<11:25:33, 3.04s/it]

@willchao612
Copy link

Seems reducing batch size will suppress this error

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