Better error message when missing memory on the GPU.
Merge pull request #1530 from nouiz/err_msg

Better error message when missing memory on the GPU.