ColossalAI icon indicating copy to clipboard operation
ColossalAI copied to clipboard

No module named 'colossal_C'

Open frankxyy opened this issue 3 years ago • 6 comments

After installing, i still meet error when trying to import colossal_C

frankxyy avatar Oct 28 '22 16:10 frankxyy

Plus: I build from the source code as belows:

git clone https://github.com/hpcaitech/ColossalAI.git cd ColossalAI

install dependency

pip install -r requirements/requirements.txt

install colossalai

pip install .

frankxyy avatar Oct 28 '22 17:10 frankxyy

Hi, I guess our CUDA extensions are not correctly installed. Please make sure you are building colossalai with CUDA, and your CUDA version should be the same as the version of cudatoolkit of pytorch. You could run nvcc -V and python -c "import torch; print(torch.version.cuda)" to check the versions.

kurisusnowdeng avatar Oct 30 '22 03:10 kurisusnowdeng

@kurisusnowdeng it seems that in the setup.py file, the variable CUDA_HOME is not set. So the following code cannot get the correct value of this variable.

frankxyy avatar Oct 31 '22 14:10 frankxyy

Problem solved,the reason is the full version of cuda toolkit is not installed on the host machine.

frankxyy avatar Nov 03 '22 03:11 frankxyy

@frankxyy

I met the same problem, could you tell me how you install the full version of cuda toolkit.

bestbzw avatar Jan 05 '23 08:01 bestbzw

@bestbzw I believe our dockerfile is a good reference. https://github.com/hpcaitech/ColossalAI/blob/main/docker/Dockerfile#L4

feifeibear avatar Jan 05 '23 08:01 feifeibear

We have updated a lot. This issue was closed due to inactivity. Thanks. https://github.com/hpcaitech/ColossalAI#Installation

binmakeswell avatar Apr 13 '23 04:04 binmakeswell