cupy.cuda.memory.OutOfMemoryError: out of memory to allocate

Asked 1 years ago, Updated 1 years ago, 72 views

There is an error as per the title.

 python gpucuda cudnn chain

Please tell me the countermeasures.
Due to the program configuration, I run del and process images, but I can't reduce the image size, reduce the batch size, or change the network...

I'm sorry for being selfish, but I appreciate your cooperation.

python chainer cuda gpu

2022-09-30 20:21

1 Answers

If you don't want to use multiple GPUs, there is a function called F.forget. This function can free memory by removing the intermediate feature .array.

Also, if you can use multi-GPU, Data parallelization using multi-GPU is also helpful.
In this case, a minimum batch size of 1 must pass forward-backward.


2022-09-30 20:21

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.