MemoryError: cuMemAlloc failed: out of memory

MemoryError: cuMemAlloc failed: out of memory

How can I solve this problem when I am running a test data set to refine the 3D structure?

Hi,

I have been encountering with problems during 2D classification. Could you please help me?

Below is the error:

Traceback (most recent call last):
File “/home/student/cryosparc/cryosparc-compute/sparc/streamlog.py”, line 438, in run_with_except_hook
run_old(*args, **kw)
File “/home/student/cryosparc/cryosparc-compute/engine/cuda_core.py”, line 86, in run
self.target(*self.args, dev=self.dev, thidx=self.thidx)
File “/home/student/cryosparc/cryosparc-compute/engine/engine.py”, line 803, in work
ET.compute_resid_pow() # do this even if not do_align because we have to compare the different structures
File “/home/student/cryosparc/cryosparc-compute/engine/engine.py”, line 261, in compute_resid_pow
self.ensure_allocated(‘resid_pow’, (self.N_D, self.N_K, self.N_RS_aligned, self.N_SS), n.float32)
File “/home/student/cryosparc/cryosparc-compute/engine/engine.py”, line 52, in ensure_allocated
new = cuda_core.allocate_gpu(shape, dtype, curr)
File “/home/student/cryosparc/cryosparc-compute/engine/cuda_core.py”, line 109, in allocate_gpu
ret = gpuarray.empty(shape, dtype=dtype)
File “/home/student/cryosparc/anaconda2/lib/python2.7/site-packages/pycuda/gpuarray.py”, line 209, in init
self.gpudata = self.allocator(self.size * self.dtype.itemsize)
MemoryError: cuMemAlloc failed: out of memory

Thanks,
Prad

You’ve run out of GPU memory. Maybe try using a smaller box size?

Oli

Thank you! I will try smaller box size.