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

out of memory error again.... #461

Open
zwx8981 opened this issue Mar 13, 2016 · 2 comments
Open

out of memory error again.... #461

zwx8981 opened this issue Mar 13, 2016 · 2 comments

Comments

@zwx8981
Copy link

zwx8981 commented Mar 13, 2016

Error using vl_nnconv
vl::impl::nnconv_forward_blas: getWorkspace [out of memory error]

Error in vl_simplenn (line 288)
res(i+1).x = vl_nnconv(res(i).x, l.weights{1}, l.weights{2}, ...

Error in get_dcnn_features (line 117)
res = vl_simplenn(net, im_resized, [], res, ...

That's the error I met, I used GPU mode to run the program (if I use 'CPU' mode, everything is ok except the speed.... ) Is this caused by the limitation of gpu memory? I've already set the batchSize to 1 to check but it still occured. The model I run is VGG-19, I also tried VGG-16, both of them have this problem.(While VGG-M works well). I must introduce my GPU, it's a GTX 980m with 8GB ram, I can't believe such a cards can not even process one image using the VD model. Anyone know something about it? Thank you.

(I should mention that this error occurs only when the size of input image exceed a certain value(In this case, a 480x640 image works well but a 1000*990 image met the problem.)

@zwx8981 zwx8981 changed the title out of memory problem again.... out of memory error again.... Mar 13, 2016
@cheer37
Copy link

cheer37 commented Mar 14, 2016

You get the error at first as soon as run of Matlab?
I suggest you check the gpu memory usage by tools like GPU-Z first.
sometimes Matlab can't free leaked garbage by previous execution. so You are able to have to reset your gpu in Matlab by reset(gpu_ID) command.

If you are not in above case, you should resize your input image, try to increase to another size, not 1000x990, because I doubt it would be at only 640x480.
Cheer.

@zwx8981
Copy link
Author

zwx8981 commented Mar 14, 2016

@cheer37 Thank you, I think the size of the image is the primary cause. Cause no need for resizing of the input image is one feature of this algorithm(for better performance, higher classification accuracy or something), there is no solution for this case now. I just set a try-catch to proceed those images whose size exceed the threshold using CPU mode. (Really slow...)

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