CUDA_ERROR_OUT_OF_MEMORY

i am training 318 images of 1024 1024 1 size. These are the properties of my GPU.
Name: 'Quadro K6000'
Index: 1
ComputeCapability: '3.5'
SupportsDouble: 1
DriverVersion: 9
ToolkitVersion: 8
MaxThreadsPerBlock: 1024
MaxShmemPerBlock: 49152
MaxThreadBlockSize: [1024 1024 64]
MaxGridSize: [2.1475e+09 65535 65535]
SIMDWidth: 32
TotalMemory: 1.2885e+10
MultiprocessorCount: 15
ClockRateKHz: 901500
ComputeMode: 'Default'
GPUOverlapsTransfers: 1
KernelExecutionTimeout: 1
CanMapHostMemory: 1
DeviceSupported: 1
DeviceSelected: 1
I am using minibatchsize '5'.
layers = [
imageInputLayer([1024 1024 1]);
convolution2dLayer(3,16)
batchNormalizationLayer;
reluLayer();
averagePooling2dLayer(2,'Stride',2);
dropoutLayer
convolution2dLayer(3,32);
batchNormalizationLayer;
reluLayer();
averagePooling2dLayer(2,'Stride',2);
dropoutLayer
fullyConnectedLayer(2);
softmaxLayer();
classificationLayer()];
I get CUDA out of memory error.Help please.

3 Commenti

Joss Knight
Joss Knight il 6 Ago 2018
I'm a little surprised by this, although it is unusual to be using such high resolution images at the input. Try setting the stride of the first convolutional layer to 2 or 3 to get the resolution down quicker. Use the Network Analyzer to ensure that you are down to 1x1 in spatial dimensions by the time you get to your final Fully Connected layer (you are on 254x254, which means your network is unlikely to be very effective anyway).
Saira charan
Saira charan il 7 Ago 2018
I've changed the stride to 3 but it doesnot make any difference. I'm using MATLAB R2017b and network analyzer is for R2018a. What would you suggest, i don't want to lose much information, what size should i resize my images?
Joss Knight
Joss Knight il 8 Ago 2018
Modificato: Joss Knight il 8 Ago 2018
All the standard networks use ImageNet data at 227x227 or 224x224. Can you upgrade MATLAB?

Accedi per commentare.

Risposte (0)

Categorie

Scopri di più su Deep Learning Toolbox in Centro assistenza e File Exchange

Prodotti

Release

R2017b

Richiesto:

il 6 Ago 2018

Modificato:

il 8 Ago 2018

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by