Large training set in Semantic Segmentation
Mostrar comentarios más antiguos
We are training a SegNet using a dataset composed of 26000 images (and 26000 associated image labels) of 256x256 pixels. The training does not start due to insufficient memory (our GPU has 6.8 GB of available memory according to the gpuDevice() command) even if the MiniBatchSize is set to 1. Obviously, we are using a pixelLabelImageDatastore to pass the dataset to the training function. It seems that the only way to solve this problem is to reduce the amount of the images of our dataset (but we would need even MORE).
We would like to know what is the best way to overcome this problem (splitting the dataset into subsets, using DispatchInBackground to pass fewer data to the GPU)?
Thank you in advance.
4 comentarios
Joss Knight
el 2 de Ag. de 2018
Your data exists as a single huge 4-D array, or as files?
Gaia Pavoni
el 3 de Ag. de 2018
Joss Knight
el 3 de Ag. de 2018
Can you give some example code? Simply calling trainNetwork with an imageDatastore does not attempt to load all the images onto the GPU; the amount of memory needed is related to the size and depth of the network and the MiniBatchSize. So if you are running out of memory with a MiniBatchSize of 1, you should run out of memory with a dataset of a single image, and reducing the number of images will make no difference. Either you would need a bigger GPU, or a different network design that doesn't need as much memory.
Birju Patel
el 9 de Ag. de 2018
Can you paste in the error message so we can see where the error occurs while running the example?
Respuestas (1)
Gaia Pavoni
el 3 de Ag. de 2018
0 votos
1 comentario
Marya Rasib
el 14 de Mzo. de 2021
Can you share your code with us please, i am facing the issue, " {"out of memory. Type "help memory" for your options. caused by: out of memory. Type "help memory " for your options"}. Thanks in advance
Categorías
Más información sobre Semantic Segmentation en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!