Error when installing gpu-tools

Hello, I’m trying to install gpu-tools with pip however one of its dependency pyopencl has an issue:

gcc -pthread -B /opt/conda/compiler_compat -Wl,–sysroot=/ -Wsign-compare -fwrapv -Wall -O3 -DNDEBUG -fPIC -DPYGPU_PACKAGE=pyopencl -DPYGPU_PYOPENCL=1 -Ipybind11/include -I/tmp/pip-build-env-oaq8_51y/overlay/lib/python3.7/site-packages/pybind11/include -I/tmp/pip-build-env-oaq8_51y/overlay/lib/python3.7/site-packages/pybind11/include -I/tmp/pip-build-env-oaq8_51y/overlay/lib/python3.7/site-packages/numpy/core/include -I/opt/conda/include/python3.7m -c src/wrap_constants.cpp -o build/temp.linux-x86_64-3.7/src/wrap_constants.o -fvisibility=hidden -DVERSION_INFO=“2020.2” -std=gnu++14 -fvisibility=hidden
In file included from src/wrap_constants.cpp:30:0:
src/wrap_cl.hpp:57:10: fatal error: CL/cl.h: No such file or directory
#include <CL/cl.h>
^~~~~~~~~
compilation terminated.
error: command ‘gcc’ failed with exit status 1

ERROR: Failed building wheel for pyopencl
Failed to build pyopencl
ERROR: Could not build wheels for pyopencl which use PEP 517 and cannot be installed directly

1 Like

Hi there!

Try installing pyopencl via conda, e.g. conda install pyopencl . I think that will work.

Hello!
Thank you it seems to work!

1 Like

Great, glad to hear that!