CuDF and tensorflow GPU compatibility issues in python

104 views Asked by At

I have written few codes where I need tensorflow (using gpu) and cudf, cupy all together. Before, it was not a problem but now, if I install: conda create --solver=libmamba -n rapids-23.12 -c rapidsai -c conda-forge -c nvidia cudf=23.12 python=3.9 cuda-version=11.2 tensorflow tensorflow can only use CPU and can not utilize GPU. Even, I tried pip install tensorflow-gpu and pip install tensorflow[and-cuda] and the problem exists as cudf requires protobuf <5, >=4.21 and tensorflow for gpu requires protobuf<3.20,>=3.9.2. Is there any way so that I can install all the rapids packages including cudf and tensorflow which can utilize GPU? ANY HELP WOULD BE APPRECIATED.

1

There are 1 answers

1
Bradley Dice On

Using cuda-version=12.0 instead of cuda-version=11.2 should fix this problem. You will need CUDA driver 525 or higher to use CUDA 12.

CUDA 11 builds of TensorFlow 2.15 aren't working right now. The conda-forge maintainers are seeking a motivated contributor to help fix them: https://github.com/conda-forge/tensorflow-feedstock/pull/367#issuecomment-1890784430

Only TensorFlow 2.15 is new enough to be compatible with other dependencies (protobuf, libabseil) that cudf relies on, so older builds of TensorFlow 2.14 (which had working CUDA 11 support) aren't compatible with cudf 23.12.

See also this GitHub issue for more information: https://github.com/rapidsai/cudf/issues/14963