无法为 pycuda 制造轮子

问题描述 投票:0回答:2

在ubuntu上安装pip pycuda时收到错误如下:

command '/usr/bin/x86_64-linux-gnu-gcc' failed with exit code 1
note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for pycuda
Failed to build pycuda
ERROR: Could not build wheels for pycuda, which is required to install pyproject.toml-based projects
python pip pycuda
2个回答
1
投票

我通过这样做解决了问题:

对于 Python 2.x 使用:

sudo apt-get install python-dev

对于 Python 2.7 使用:

sudo apt-get install libffi-dev

对于 Python 3.x 使用:

sudo apt-get install python3-dev

或者对于特定版本的 Python 3,将 x 替换为

中的次要版本
sudo apt-get install python3.x-dev

0
投票

有没有人已经解决了这个问题,我尝试安装

python3.10-dev
和其他软件包,例如
build-essential libdbus-glib-1-dev libgirepository1.0-dev libpython3.10-dev libcairo2 libcairo2-dev gir1.2-gstreamer-1.0 python3.10-dev libffi-dev python3-libnvinfer python3-libnvinfer-dev

任何解决方案,请

© www.soinside.com 2019 - 2024. All rights reserved.