pyg-lib
pyg-lib copied to clipboard
An error occurred while installing from the source on aarch64.
😵 Describe the installation problem
An error occurred while installing from the source on aarch64. Actually, I want to install torch-geometric on aarch64. I executed the following command.
pip install ninja wheel
pip install git+https://github.com/pyg-team/pyg-lib.git
However, the following error occurred.
Running command git clone --filter=blob:none --quiet https://github.com/pyg-team/pyg-lib.git /tmp/pip-req-build-i0glx2l_
Running command git submodule update --init --recursive -q
error: subprocess-exited-with-error
× python setup.py bdist_wheel did not run successfully.
│ exit code: 1
╰─
creating build/lib.linux-aarch64-cpython-38/pyg_lib/ops
copying pyg_lib/ops/scatter_reduce.py -> build/lib.linux-aarch64-cpython-38/pyg_lib/ops
copying pyg_lib/ops/__init__.py -> build/lib.linux-aarch64-cpython-38/pyg_lib/ops
running build_ext
-- The C compiler identification is unknown
-- The CXX compiler identification is unknown
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- broken
CMake Error at /usr/share/cmake/Modules/CMakeTestCCompiler.cmake:60 (message):
The C compiler
"/usr/bin/cc"
is not able to compile a simple test program.
It fails with the following output:
Change Dir: /tmp/pip-req-build-i0glx2l_/build/temp.linux-aarch64-cpython-38/CMakeFiles/CMakeTmp
Run Build Command(s):/xxx/anaconda3/envs/env_name/bin/ninja cmTC_3cc80 && [1/2] Building C object CMakeFiles/cmTC_3cc80.dir/testCCompiler.c.o
FAILED: CMakeFiles/cmTC_3cc80.dir/testCCompiler.c.o
/usr/bin/cc -o CMakeFiles/cmTC_3cc80.dir/testCCompiler.c.o -c testCCompiler.c
cc1: error: /xxxxx/anaconda3/bin: Permission denied
cc1: error: /xxxxx/anaconda3/bin: Permission denied
cc1: error: /xxxxx/anaconda3/bin: Permission denied
cc1: error: /xxxxx/anaconda3/bin: Permission denied
cc1: error: /xxxxx/anaconda3/bin: Permission denied
cc1: error: /root/bin: Permission denied
ninja: build stopped: subcommand failed.
File "/xxx/anaconda3/envs/env_name/lib/python3.8/site-packages/setuptools/_distutils/dist.py", line 969, in run_commands
self.run_command(cmd)
File "/xxx/anaconda3/envs/env_name/lib/python3.8/site-packages/setuptools/dist.py", line 1234, in run_command
super().run_command(command)
File "/xxx/anaconda3/envs/env_name/lib/python3.8/site-packages/setuptools/_distutils/dist.py", line 988, in run_command
cmd_obj.run()
File "/xxx/anaconda3/envs/env_name/lib/python3.8/site-packages/wheel/bdist_wheel.py", line 364, in run
self.run_command("build")
File "/xxx/anaconda3/envs/env_name/lib/python3.8/site-packages/setuptools/_distutils/cmd.py", line 318, in run_command
self.distribution.run_command(command)
File "/xxx/anaconda3/envs/env_name/lib/python3.8/site-packages/setuptools/dist.py", line 1234, in run_command
super().run_command(command)
File "/xxx/anaconda3/envs/env_name/lib/python3.8/site-packages/setuptools/_distutils/dist.py", line 988, in run_command
cmd_obj.run()
File "/xxx/anaconda3/envs/env_name/lib/python3.8/site-packages/setuptools/_distutils/command/build.py", line 131, in run
self.run_command(cmd_name)
File "/xxx/anaconda3/envs/env_name/lib/python3.8/site-packages/setuptools/_distutils/cmd.py", line 318,
in run_command
self.distribution.run_command(command)
File "/xxx/anaconda3/envs/env_name/lib/python3.8/site-packages/setuptools/dist.py", line 1234, in run_c
ommand
super().run_command(command)
File "/xxx/anaconda3/envs/env_name/lib/python3.8/site-packages/setuptools/_distutils/dist.py", line 988
, in run_command
cmd_obj.run()
File "/xxx/anaconda3/envs/env_name/lib/python3.8/site-packages/setuptools/command/build_ext.py", line 8
4, in run
_build_ext.run(self)
File "/xxx/anaconda3/envs/env_name/lib/python3.8/site-packages/setuptools/_distutils/command/build_ext.
py", line 345, in run
self.build_extensions()
File "/xxx/anaconda3/envs/env_name/lib/python3.8/site-packages/setuptools/_distutils/command/build_ext.
py", line 467, in build_extensions
self._build_extensions_serial()
File "/xxx/anaconda3/envs/env_name/lib/python3.8/site-packages/setuptools/_distutils/command/build_ext.
py", line 493, in _build_extensions_serial
self.build_extension(ext)
File "/tmp/pip-req-build-i0glx2l_/setup.py", line 82, in build_extension
subprocess.check_call(['cmake', ext.sourcedir] + cmake_args,
File "/xxx/anaconda3/envs/env_name/lib/python3.8/subprocess.py", line 364, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['cmake', '/tmp/pip-req-build-i0glx2l_', '-DBUILD_TEST=OFF', '-DBUILD_BENCHMARK=OFF', '-DUSE_PYTHON=ON', '-
DWITH_CUDA=OFF', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=/tmp/pip-req-build-i0glx2l_/build/lib.linux-aarch64-cpython-38', '-DCMAKE_BUILD_TYPE=RELEASE', '-DCMAK
E_PREFIX_PATH=/xxx/anaconda3/envs/env_name/lib/python3.8/site-packages/torch/share/cmake', '-GNinja']' returned
non-zero exit status 1.
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for pyg-lib
ERROR: Could not build wheels for pyg-lib, which is required to install pyproject.toml-based projects
I don't know what problems I have encountered and what good solutions are there. Or how to install torch-geometric on aarch64? The document only mentions that it can be installed from the source. At present, I am just an ordinary user of the server, and I don't have root permission.
Environment
-
pyg-lib
version: - PyTorch version: 1.11.0+cu113
- OS: Linux dlhpcshare-ccs-cli-1 4.19.90-24.4.v2101.ky10.aarch64
- Python version: 3.8.18
- CUDA/cuDNN version: 11.3 (Build cuda_11.3.r11.3/compiler.29745058_0)
- How you installed PyTorch and
pyg-lib
(conda
,pip
, source): source - Any other relevant information: aarch64
Hm, I am not totally sure. Have you tried googling for
-- Check for working C compiler: /usr/bin/cc -- broken
CMake Error at /usr/share/cmake/Modules/CMakeTestCCompiler.cmake:60 (message):
The C compiler
"/usr/bin/cc"
is not able to compile a simple test program.
This definitely seems to be an issue with permissions.