FastFold icon indicating copy to clipboard operation
FastFold copied to clipboard

Conda environment - no CUDA

Open arneelof opened this issue 3 years ago • 1 comments

Thanks for making this available, just a few comments on #installation

I've been trying to get the CONDA environment to work on my systems,

If I use the default environment I get the following errors:

Colossalai should be built with cuda extension to use the FP16 optimizer
If you want to activate cuda mode for MoE, please install with cuda_ext!
/proj/berzelius-2021-29/users/x_arnel/.conda/envs/FastFold/lib/python3.8/site-packages/torch/autocast_mode.py:162: UserWarning: User provided device_type of 'cuda', but CUDA is not available. Disabling
  warnings.warn('User provided device_type of \'cuda\', but CUDA is not available. Disabling')

I guess this is due to that the PyPI version of colossalai is not compiled with CUDA, see https://colossalai.org/download

Instead I had to do a postinstall: pip install colossalai==0.1.6+torch1.11cu11.3 -f https://release.colossalai.org (perhaps this can be included in the .yml file ?)

but that created problems so I had to recompile which works after some minor tweaks (wrong nvcc paths and environmental variables,)

arneelof avatar Jun 02 '22 10:06 arneelof

Thank you for your suggestion. FastFold currently does not depend on cuda_ext of colossalai. But FastFold does rely on nvcc which is compatible with the installed torch. You can check with bellow command:

$ python -c "import torch;print(torch.version.cuda)"
11.5
$ nvcc -V
nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2021 NVIDIA Corporation
Built on Thu_Nov_18_09:45:30_PST_2021
Cuda compilation tools, release 11.5, V11.5.119
Build cuda_11.5.r11.5/compiler.30672275_0

Shenggan avatar Jun 03 '22 05:06 Shenggan