Skip to content

Instantly share code, notes, and snippets.

@glyphx
Created January 2, 2017 16:39
Show Gist options
  • Save glyphx/17f3936cedcedad3679f6ea9bf6c0f90 to your computer and use it in GitHub Desktop.
Save glyphx/17f3936cedcedad3679f6ea9bf6c0f90 to your computer and use it in GitHub Desktop.
THEANO_FLAGS with cnmem = .8 crashed me, .7 worked
C:\toolkits\anaconda2-4.2.0\python.exe C:/toolkits/cpu_gpu_test.py
ERROR (theano.sandbox.cuda): ERROR: Not using GPU. Initialisation of device gpu failed:
initCnmem: cnmemInit call failed! Reason=CNMEM_STATUS_OUT_OF_MEMORY. numdev=1
Traceback (most recent call last):
File "C:/toolkits/cpu_gpu_test.py", line 2, in <module>
from theano import function, config, shared, sandbox
File "C:\toolkits\anaconda2-4.2.0\lib\site-packages\theano-0.8.2-py2.7.egg\theano\__init__.py", line 111, in <module>
theano.sandbox.cuda.tests.test_driver.test_nvidia_driver1()
File "C:\toolkits\anaconda2-4.2.0\lib\site-packages\theano-0.8.2-py2.7.egg\theano\sandbox\cuda\tests\test_driver.py", line 38, in test_nvidia_driver1
if not numpy.allclose(f(), a.sum()):
File "C:\toolkits\anaconda2-4.2.0\lib\site-packages\theano-0.8.2-py2.7.egg\theano\compile\function_module.py", line 871, in __call__
storage_map=getattr(self.fn, 'storage_map', None))
File "C:\toolkits\anaconda2-4.2.0\lib\site-packages\theano-0.8.2-py2.7.egg\theano\gof\link.py", line 314, in raise_with_op
reraise(exc_type, exc_value, exc_trace)
File "C:\toolkits\anaconda2-4.2.0\lib\site-packages\theano-0.8.2-py2.7.egg\theano\compile\function_module.py", line 859, in __call__
outputs = self.fn()
RuntimeError: Cuda error: kernel_reduce_ccontig_node_97496c4d3cf9a06dc4082cc141f918d2_0: out of memory. (grid: 1 x 1; block: 256 x 1 x 1)
Apply node that caused the error: GpuCAReduce{add}{1}(<CudaNdarrayType(float32, vector)>)
Toposort index: 0
Inputs types: [CudaNdarrayType(float32, vector)]
Inputs shapes: [(10000,)]
Inputs strides: [(1,)]
Inputs values: ['not shown']
Outputs clients: [[HostFromGpu(GpuCAReduce{add}{1}.0)]]
HINT: Re-running with most Theano optimization disabled could give you a back-trace of when this node was created. This can be done with by setting the Theano flag 'optimizer=fast_compile'. If that does not work, Theano optimizations can be disabled with 'optimizer=None'.
HINT: Use the Theano flag 'exception_verbosity=high' for a debugprint and storage map footprint of this apply node.
Process finished with exit code 1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment