askerlee / segtran

Medical Image Segmentation using Squeeze-and-Expansion Transformers
214 stars 50 forks source link

test3d.py failure #16

Closed wshi8 closed 2 years ago

wshi8 commented 3 years ago

Hi Dr Lee,

I tried to run test3d.py for a set of 110 test images a few times, but it somehow always exit unexpectedly around 70-ish images without any error. So far, I have never successfully finished the 110 images.

Any advice?

Best, Wendy

askerlee commented 3 years ago

This is weird. I never experienced such problems (I've run segtran on different computers). Could you check whether your CUDA version is not too old, and the pytorch installed matches your CUDA version?

459737087 commented 3 years ago

RuntimeError: cuda runtime error (100) : no CUDA-capable device is detected at /pytorch/aten/src/THC/THCGeneral.cpp:47

I met this question in test3d.py

459737087 commented 3 years ago

I know how to resolve it, your code contains tensorflow and pytorch,and I should change args.gpu 1 to 0,my gpu default is 0.

askerlee commented 3 years ago

Oh I see. I'll change the default arg.gpu to 0 to avoid such errors. Thanks.