Ryo-Ito / brain_segmentation

Implementation of VoxResNet for 3D brain segmentation
MIT License
66 stars 17 forks source link

Get MemoryError when I run train.py without gpu #4

Open Kaido0 opened 7 years ago

Kaido0 commented 7 years ago
Using gpu device 0: GeForce GT 525M (CNMeM is enabled with initial size: 50.0% of memory, cuDNN not available)
Namespace(display_step=1000, gpu=-1, input_file='dataset_train.json', iteration=10000, learning_rate=0.001, n_batch=1, out='vrn.npz', shape=[80, 80, 80], weight_decay=0.0005)
Traceback (most recent call last):
  File "train.py", line 84, in <module>
    main()
  File "train.py", line 67, in main
    logits = vrn(x_train, train=True)
  File "/home/kaido/Download/brain_segmentation-master/model.py", line 104, in __call__
    c4 = self.c4conv(c4)
  File "/home/kaido/anaconda2/lib/python2.7/site-packages/chainer/links/connection/convolution_nd.py", line 83, in __call__
    use_cudnn=self.use_cudnn, cover_all=self.cover_all)
  File "/home/kaido/anaconda2/lib/python2.7/site-packages/chainer/functions/connection/convolution_nd.py", line 371, in convolution_nd
    return func(x, W)
  File "/home/kaido/anaconda2/lib/python2.7/site-packages/chainer/function.py", line 199, in __call__
    outputs = self.forward(in_data)
  File "/home/kaido/anaconda2/lib/python2.7/site-packages/chainer/functions/connection/convolution_nd.py", line 176, in forward
    return self._forward_xp(x, W, b, numpy)
  File "/home/kaido/anaconda2/lib/python2.7/site-packages/chainer/functions/connection/convolution_nd.py", line 75, in _forward_xp
    x, ksize, stride, pad, cover_all=self.cover_all)
  File "/home/kaido/anaconda2/lib/python2.7/site-packages/chainer/utils/conv_nd.py", line 34, in im2col_nd_cpu
    col = numpy.ndarray(shape, dtype=img.dtype)
MemoryError
Ryo-Ito commented 7 years ago

I recommend not to use the network without gpu, because it would take forever.