Hi, I met a problem as follows:
BLAS : Program is Terminated. Because you tried to allocate too many memory regions.
After setting threads as follows,
export OPENBLAS_NUM_THREADS=1
export GOTO_NUM_THREADS=1
export OMP_NUM_THREADS=1
The problem was solved. Therefore, the problem is aroused from multi-thread of CPUs.
I just used 50 or 100 images as a batch, where each image is 3224224. The machine has 2 GPUs  – Tesla M40, 2 CPUs–Intel Xeon E5 v4 CPU. Because I cannot connect with conda, I download Pytorch and torchvision sources, and compile them. The cuda version is 7.5, the cudnn version is 5.1.
How can I deal with the problem? Thank you beforehand.