当前位置:网站首页>Summary of solving the Jetson nano installation onnx error (error: failed building wheel for onnx)
Summary of solving the Jetson nano installation onnx error (error: failed building wheel for onnx)
2022-07-02 07:53:00 【Silent clouds】
ERROR: Failed building wheel for onnx
Solve the problem of dependence
No installation protobuf
Error information reference post :https://github.com/onnx/onnx/issues/2481
terms of settlement :pip3 install protobuf
Protobuf compiler not found
error message :
ERROR: Command errored out with exit status 1:
command: /usr/bin/python3 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-38btlr9d/onnx_c5170763f41345449ba410a0157122af/setup.py'"'"'; __file__='"'"'/tmp/pip-install-38btlr9d/onnx_c5170763f41345449ba410a0157122af/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /tmp/pip-wheel-jy6zy5qw
cwd: /tmp/pip-install-38btlr9d/onnx_c5170763f41345449ba410a0157122af/
Complete output (68 lines):
fatal: Is not a git Warehouse ( Or any parent directory ):.git
/home/yaoz/.local/lib/python3.6/site-packages/setuptools/dist.py:645: UserWarning: Usage of dash-separated 'license-file' will not be supported in future versions. Please use the underscore name 'license_file' instead
% (opt, underscore_opt))
/home/yaoz/.local/lib/python3.6/site-packages/setuptools/dist.py:645: UserWarning: Usage of dash-separated 'license-file' will not be supported in future versions. Please use the underscore name 'license_file' instead
% (opt, underscore_opt))
running bdist_wheel
running build
running build_py
running create_version
running cmake_build
-- The C compiler identification is GNU 7.5.0
-- The CXX compiler identification is GNU 7.5.0
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
Generated: /tmp/pip-install-38btlr9d/onnx_c5170763f41345449ba410a0157122af/.setuptools-cmake-build/onnx/onnx-ml.proto
CMake Error at CMakeLists.txt:248 (message):
Protobuf compiler not found
Call Stack (most recent call first):
CMakeLists.txt:279 (relative_protobuf_generate_cpp)
-- Configuring incomplete, errors occurred!
See also "/tmp/pip-install-38btlr9d/onnx_c5170763f41345449ba410a0157122af/.setuptools-cmake-build/CMakeFiles/CMakeOutput.log".
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-install-38btlr9d/onnx_c5170763f41345449ba410a0157122af/setup.py", line 334, in <module>
'backend-test-tools = onnx.backend.test.cmd_tools:main',
File "/home/yaoz/.local/lib/python3.6/site-packages/setuptools/__init__.py", line 153, in setup
return distutils.core.setup(**attrs)
File "/usr/lib/python3.6/distutils/core.py", line 148, in setup
dist.run_commands()
File "/usr/lib/python3.6/distutils/dist.py", line 955, in run_commands
self.run_command(cmd)
File "/usr/lib/python3.6/distutils/dist.py", line 974, in run_command
cmd_obj.run()
File "/usr/lib/python3/dist-packages/wheel/bdist_wheel.py", line 204, in run
self.run_command('build')
File "/usr/lib/python3.6/distutils/cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "/usr/lib/python3.6/distutils/dist.py", line 974, in run_command
cmd_obj.run()
File "/usr/lib/python3.6/distutils/command/build.py", line 135, in run
self.run_command(cmd_name)
File "/usr/lib/python3.6/distutils/cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "/usr/lib/python3.6/distutils/dist.py", line 974, in run_command
cmd_obj.run()
File "/tmp/pip-install-38btlr9d/onnx_c5170763f41345449ba410a0157122af/setup.py", line 209, in run
self.run_command('cmake_build')
File "/usr/lib/python3.6/distutils/cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "/usr/lib/python3.6/distutils/dist.py", line 974, in run_command
cmd_obj.run()
File "/tmp/pip-install-38btlr9d/onnx_c5170763f41345449ba410a0157122af/setup.py", line 195, in run
subprocess.check_call(cmake_args)
File "/usr/lib/python3.6/subprocess.py", line 311, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['/usr/bin/cmake', '-DPYTHON_INCLUDE_DIR=/usr/include/python3.6m', '-DPYTHON_EXECUTABLE=/usr/bin/python3', '-DBUILD_ONNX_PYTHON=ON', '-DCMAKE_EXPORT_COMPILE_COMMANDS=ON', '-DONNX_NAMESPACE=onnx', '-DPY_EXT_SUFFIX=.cpython-36m-aarch64-linux-gnu.so', '-DCMAKE_BUILD_TYPE=Release', '-DONNX_ML=1', '/tmp/pip-install-38btlr9d/onnx_c5170763f41345449ba410a0157122af']' returned non-zero exit status 1.
----------------------------------------
ERROR: Failed building wheel for onnx
Question why : The lack of Protobuf compiler
terms of settlement ( Install other dependencies ):
sudo apt-get install -y libprotobuf-dev protobuf-compiler python3-scipy
notes : To install scipy Proposed installation 1.4.1 edition , I suggest you refer to my last post :jetson nano install tensorflow Record on pit (scipy1.4.1)
fatal error: Python.h: There is no file or directory
The specific errors are as follows :
ERROR: Command errored out with exit status 1:
command: /usr/bin/python3 /home/yaoz/.local/lib/python3.6/site-packages/pip/_vendor/pep517/_in_process.py build_wheel /tmp/tmpm_ittf0y
cwd: /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7
Complete output (247 lines):
fatal: Is not a git Warehouse ( Or any parent directory ):.git
running bdist_wheel
running build
running build_py
running create_version
running cmake_build
-- The C compiler identification is GNU 7.5.0
-- The CXX compiler identification is GNU 7.5.0
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Found PythonInterp: /usr/bin/python3 (found version "3.6.9")
-- Found PythonLibs: /usr/lib/aarch64-linux-gnu/libpython2.7.so
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - not found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Found Protobuf: /usr/lib/aarch64-linux-gnu/libprotobuf.so;-lpthread (found version "3.0.0")
Generated: /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/.setuptools-cmake-build/onnx/onnx-ml.proto
Generated: /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/.setuptools-cmake-build/onnx/onnx-operators-ml.proto
Generated: /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/.setuptools-cmake-build/onnx/onnx-data.proto
CMake Warning at CMakeLists.txt:416 (find_package):
By not providing "Findpybind11.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "pybind11",
but CMake did not find one.
Could not find a package configuration file provided by "pybind11"
(requested version 2.2) with any of the following names:
pybind11Config.cmake
pybind11-config.cmake
Add the installation prefix of "pybind11" to CMAKE_PREFIX_PATH or set
"pybind11_DIR" to a directory containing one of the above files. If
"pybind11" provides a separate development package or SDK, be sure it has
been installed.
--
-- ******** Summary ********
-- CMake version : 3.10.2
-- CMake command : /usr/bin/cmake
-- System : Linux
-- C++ compiler : /usr/bin/c++
-- C++ compiler version : 7.5.0
-- CXX flags : -Wnon-virtual-dtor
-- Build type : Release
-- Compile definitions :
-- CMAKE_PREFIX_PATH :
-- CMAKE_INSTALL_PREFIX : /usr/local
-- CMAKE_MODULE_PATH :
--
-- ONNX version : 1.8.1
-- ONNX NAMESPACE : onnx
-- ONNX_BUILD_TESTS : OFF
-- ONNX_BUILD_BENCHMARKS : OFF
-- ONNX_USE_LITE_PROTO : OFF
-- ONNXIFI_DUMMY_BACKEND : OFF
-- ONNXIFI_ENABLE_EXT : OFF
--
-- Protobuf compiler : /usr/bin/protoc
-- Protobuf includes : /usr/include
-- Protobuf libraries : /usr/lib/aarch64-linux-gnu/libprotobuf.so;-lpthread
-- BUILD_ONNX_PYTHON : ON
-- Python version :
-- Python executable : /usr/bin/python3
-- Python includes : /usr/include/python3.6m
-- Configuring done
-- Generating done
-- Build files have been written to: /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/.setuptools-cmake-build
Scanning dependencies of target gen_onnx_proto
Scanning dependencies of target onnxifi_dummy
Scanning dependencies of target onnxifi_loader
[ 4%] Building C object CMakeFiles/onnxifi_dummy.dir/onnx/onnxifi_dummy.c.o
[ 4%] Running gen_proto.py on onnx/onnx.in.proto
[ 4%] Building C object CMakeFiles/onnxifi_loader.dir/onnx/onnxifi_loader.c.o
/tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/onnx/onnxifi_dummy.c: In function ‘onnxGetExtensionFunctionAddress’:
/tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/onnx/onnxifi_dummy.c:173:21: warning: assignment from incompatible pointer type [-Wincompatible-pointer-types]
*function = &onnxGetExtensionFunctionAddress;
^
/tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/onnx/onnxifi_dummy.c:176:21: warning: assignment from incompatible pointer type [-Wincompatible-pointer-types]
*function = &onnxSetIOAndRunGraph;
^
[ 6%] Linking C static library libonnxifi_loader.a
Processing /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/onnx/onnx.in.proto
Writing /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/.setuptools-cmake-build/onnx/onnx-ml.proto
Writing /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/.setuptools-cmake-build/onnx/onnx-ml.proto3
generating /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/.setuptools-cmake-build/onnx/onnx_pb.py
[ 7%] Linking C shared library libonnxifi_dummy.so
[ 9%] Running C++ protocol buffer compiler on /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/.setuptools-cmake-build/onnx/onnx-ml.proto
[ 9%] Built target onnxifi_loader
Scanning dependencies of target onnxifi_wrapper
[ 9%] Built target onnxifi_dummy
[ 10%] Building C object CMakeFiles/onnxifi_wrapper.dir/onnx/onnxifi_wrapper.c.o
Writing mypy to onnx/onnx_ml_pb2.pyi
[ 12%] Linking C shared module libonnxifi.so
[ 12%] Built target gen_onnx_proto
[ 15%] Running gen_proto.py on onnx/onnx-data.in.proto
[ 15%] Running gen_proto.py on onnx/onnx-operators.in.proto
[ 15%] Built target onnxifi_wrapper
Processing /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/onnx/onnx-data.in.proto
Writing /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/.setuptools-cmake-build/onnx/onnx-data.proto
Writing /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/.setuptools-cmake-build/onnx/onnx-data.proto3
generating /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/.setuptools-cmake-build/onnx/onnx_data_pb.py
Processing /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/onnx/onnx-operators.in.proto
Writing /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/.setuptools-cmake-build/onnx/onnx-operators-ml.proto
Writing /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/.setuptools-cmake-build/onnx/onnx-operators-ml.proto3
generating /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/.setuptools-cmake-build/onnx/onnx_operators_pb.py
[ 18%] Running C++ protocol buffer compiler on /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/.setuptools-cmake-build/onnx/onnx-operators-ml.proto
[ 18%] Running C++ protocol buffer compiler on /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/.setuptools-cmake-build/onnx/onnx-data.proto
Writing mypy to onnx/onnx_data_pb2.pyi
Writing mypy to onnx/onnx_operators_ml_pb2.pyi
Scanning dependencies of target onnx_proto
[ 21%] Building CXX object CMakeFiles/onnx_proto.dir/onnx/onnx-data.pb.cc.o
[ 21%] Building CXX object CMakeFiles/onnx_proto.dir/onnx/onnx-operators-ml.pb.cc.o
[ 22%] Building CXX object CMakeFiles/onnx_proto.dir/onnx/onnx-ml.pb.cc.o
[ 24%] Linking CXX static library libonnx_proto.a
[ 27%] Built target onnx_proto
Scanning dependencies of target onnx
[ 33%] Building CXX object CMakeFiles/onnx.dir/onnx/checker.cc.o
[ 33%] Building CXX object CMakeFiles/onnx.dir/onnx/common/ir_pb_converter.cc.o
[ 33%] Building CXX object CMakeFiles/onnx.dir/onnx/common/assertions.cc.o
[ 33%] Building CXX object CMakeFiles/onnx.dir/onnx/common/interned_strings.cc.o
[ 34%] Building CXX object CMakeFiles/onnx.dir/onnx/common/model_helpers.cc.o
[ 36%] Building CXX object CMakeFiles/onnx.dir/onnx/common/status.cc.o
[ 37%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/attr_proto_util.cc.o
[ 39%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/controlflow/defs.cc.o
[ 40%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/controlflow/old.cc.o
[ 42%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/data_type_utils.cc.o
[ 43%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/function.cc.o
[ 45%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/generator/defs.cc.o
[ 46%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/generator/old.cc.o
[ 48%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/logical/defs.cc.o
[ 50%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/logical/old.cc.o
[ 51%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/math/defs.cc.o
[ 53%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/math/old.cc.o
[ 54%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/nn/defs.cc.o
[ 56%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/nn/old.cc.o
[ 57%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/object_detection/defs.cc.o
[ 59%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/object_detection/old.cc.o
[ 60%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/quantization/defs.cc.o
[ 62%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/quantization/old.cc.o
[ 63%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/reduction/defs.cc.o
[ 65%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/reduction/old.cc.o
[ 66%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/rnn/defs.cc.o
[ 68%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/rnn/old.cc.o
[ 69%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/schema.cc.o
[ 71%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/sequence/defs.cc.o
[ 72%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/tensor/defs.cc.o
[ 74%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/tensor/old.cc.o
[ 75%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/tensor/utils.cc.o
[ 77%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/tensor_proto_util.cc.o
[ 78%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/tensor_util.cc.o
[ 80%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/traditionalml/defs.cc.o
[ 81%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/traditionalml/old.cc.o
[ 83%] Building CXX object CMakeFiles/onnx.dir/onnx/defs/training/defs.cc.o
[ 84%] Building CXX object CMakeFiles/onnx.dir/onnx/onnxifi_utils.cc.o
[ 86%] Building CXX object CMakeFiles/onnx.dir/onnx/optimizer/optimize.cc.o
[ 87%] Building CXX object CMakeFiles/onnx.dir/onnx/optimizer/pass.cc.o
[ 89%] Building CXX object CMakeFiles/onnx.dir/onnx/optimizer/pass_manager.cc.o
[ 90%] Building CXX object CMakeFiles/onnx.dir/onnx/optimizer/pass_registry.cc.o
[ 92%] Building CXX object CMakeFiles/onnx.dir/onnx/shape_inference/implementation.cc.o
[ 93%] Building CXX object CMakeFiles/onnx.dir/onnx/version_converter/convert.cc.o
[ 95%] Building CXX object CMakeFiles/onnx.dir/onnx/version_converter/helper.cc.o
[ 96%] Linking CXX static library libonnx.a
[ 96%] Built target onnx
Scanning dependencies of target onnx_cpp2py_export
[ 98%] Building CXX object CMakeFiles/onnx_cpp2py_export.dir/onnx/cpp2py_export.cc.o
In file included from /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/third_party/pybind11/include/pybind11/pytypes.h:12:0,
from /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/third_party/pybind11/include/pybind11/cast.h:13,
from /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/third_party/pybind11/include/pybind11/attr.h:13,
from /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/third_party/pybind11/include/pybind11/pybind11.h:45,
from /tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/onnx/cpp2py_export.cc:1:
/tmp/pip-install-4hcuagp3/onnx_b3380438a9fc4e2c8f80dae3fd60cfd7/third_party/pybind11/include/pybind11/detail/common.h:122:10: fatal error: Python.h: There is no file or directory
#include <Python.h>
^~~~~~~~~~
compilation terminated.
CMakeFiles/onnx_cpp2py_export.dir/build.make:62: recipe for target 'CMakeFiles/onnx_cpp2py_export.dir/onnx/cpp2py_export.cc.o' failed
make[2]: *** [CMakeFiles/onnx_cpp2py_export.dir/onnx/cpp2py_export.cc.o] Error 1
CMakeFiles/Makefile2:349: recipe for target 'CMakeFiles/onnx_cpp2py_export.dir/all' failed
make[1]: *** [CMakeFiles/onnx_cpp2py_export.dir/all] Error 2
Makefile:129: recipe for target 'all' failed
make: *** [all] Error 2
/tmp/pip-build-env-5bdpwz7b/overlay/lib/python3.6/site-packages/setuptools/dist.py:645: UserWarning: Usage of dash-separated 'license-file' will not be supported in future versions. Please use the underscore name 'license_file' instead
% (opt, underscore_opt))
Traceback (most recent call last):
File "/home/yaoz/.local/lib/python3.6/site-packages/pip/_vendor/pep517/_in_process.py", line 280, in <module>
main()
File "/home/yaoz/.local/lib/python3.6/site-packages/pip/_vendor/pep517/_in_process.py", line 263, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "/home/yaoz/.local/lib/python3.6/site-packages/pip/_vendor/pep517/_in_process.py", line 205, in build_wheel
metadata_directory)
File "/tmp/pip-build-env-5bdpwz7b/overlay/lib/python3.6/site-packages/setuptools/build_meta.py", line 217, in build_wheel
wheel_directory, config_settings)
File "/tmp/pip-build-env-5bdpwz7b/overlay/lib/python3.6/site-packages/setuptools/build_meta.py", line 202, in _build_with_temp_dir
self.run_setup()
File "/tmp/pip-build-env-5bdpwz7b/overlay/lib/python3.6/site-packages/setuptools/build_meta.py", line 254, in run_setup
self).run_setup(setup_script=setup_script)
File "/tmp/pip-build-env-5bdpwz7b/overlay/lib/python3.6/site-packages/setuptools/build_meta.py", line 145, in run_setup
exec(compile(code, __file__, 'exec'), locals())
File "setup.py", line 341, in <module>
'backend-test-tools = onnx.backend.test.cmd_tools:main',
File "/tmp/pip-build-env-5bdpwz7b/overlay/lib/python3.6/site-packages/setuptools/__init__.py", line 153, in setup
return distutils.core.setup(**attrs)
File "/usr/lib/python3.6/distutils/core.py", line 148, in setup
dist.run_commands()
File "/usr/lib/python3.6/distutils/dist.py", line 955, in run_commands
self.run_command(cmd)
File "/usr/lib/python3.6/distutils/dist.py", line 974, in run_command
cmd_obj.run()
File "/tmp/pip-build-env-5bdpwz7b/overlay/lib/python3.6/site-packages/wheel/bdist_wheel.py", line 299, in run
self.run_command('build')
File "/usr/lib/python3.6/distutils/cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "/usr/lib/python3.6/distutils/dist.py", line 974, in run_command
cmd_obj.run()
File "/usr/lib/python3.6/distutils/command/build.py", line 135, in run
self.run_command(cmd_name)
File "/usr/lib/python3.6/distutils/cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "/usr/lib/python3.6/distutils/dist.py", line 974, in run_command
cmd_obj.run()
File "setup.py", line 217, in run
self.run_command('cmake_build')
File "/usr/lib/python3.6/distutils/cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "/usr/lib/python3.6/distutils/dist.py", line 974, in run_command
cmd_obj.run()
File "setup.py", line 211, in run
subprocess.check_call(build_args)
File "/usr/lib/python3.6/subprocess.py", line 311, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['/usr/bin/cmake', '--build', '.', '--', '-j', '4']' returned non-zero exit status 2.
----------------------------------------
ERROR: Failed building wheel for onnx
Failed to build onnx
ERROR: Could not build wheels for onnx which use PEP 517 and cannot be installed directly
The reason for the error : No installation python3-dev
Try entering the command to install :sudo apt-get install python3-dev
The following error occurred :
Some packages can't be installed . If you use unstable Distribution version , This may be
Because the system cannot reach the state you require . There may be some software you need in this release
Packages have not yet been created or they have been refreshed to (Incoming) Directory move out of .
The following information may help solve the problem :
The following packages have unsatisfied dependencies :
python3-dev : rely on : python3 (= 3.6.5-3) however 3.6.7-1~18.04 It's about to be installed
rely on : libpython3-dev (= 3.6.5-3) But it will not be installed
rely on : python3.6-dev (>= 3.6.5-2~) But it will not be installed
E: Unable to fix error , Because you want some packages to be as they are , It's them that break the dependencies between packages .
terms of settlement : Use aptitude install :sudo aptitude install python3-dev
If not installed aptitude Install first :sudo apt-get install aptitude
The following “ new ” The package will be installed .
dh-python{
a} libpython3-dev{
a} libpython3.6-dev{
ab} python3-dev{
b} python3.6-dev{
ab}
0 Packages were upgraded , New installation 5 individual , 0 Will be deleted , meanwhile 0 One will not be upgraded .
Need to get 2,886 kB Archive of . After unpacking, you will use 16.8 MB.
The following packages have unsatisfied dependencies :
python3-dev : rely on : python3 (= 3.6.5-3) but 3.6.7-1~18.04 is installed
libpython3.6-dev : rely on : libpython3.6-stdlib (= 3.6.5-3) but 3.6.9-1~18.04ubuntu1 is installed
rely on : libpython3.6 (= 3.6.5-3) but 3.6.9-1~18.04ubuntu1 is installed
python3.6-dev : rely on : python3.6 (= 3.6.5-3) but 3.6.9-1~18.04ubuntu1 is installed
rely on : libpython3.6 (= 3.6.5-3) but 3.6.9-1~18.04ubuntu1 is installed
open :42; close ;591;defer: 26; Conflict ;40 . The following actions will resolve these dependencies :
keep The current version of the package is :
1) libpython3-dev [ Not installed ]
2) libpython3.6-dev [ Not installed ]
3) python3-dev [ Not installed ]
4) python3.6-dev [ Not installed ]
Whether to accept the solution ?[Y/n/q/?]
choice y enter , Will maintain the original state . It cannot be installed here because there is a problem with the official source , Not updated with the latest python3-dev package .
I checked , Official main server python3-dev The latest version of only supports python3.6.5 Version of , But my jetson nano Own is python3.6.9. If you use aptitude Forcibly downgrade the installation , So your python3 The environment will collapse directly , Any module you import will appear : Illegal order ( The core has been dumped ) Error of . So here's a reminder .
The solution I found is : Switch domestic ubuntu Source ( Tutorial tips from Taobao merchants : Switching domestic sources is risky , Other incompatibilities may occur , But I haven't found any sequelae yet ):
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/ bionic main multiverse restricted universe
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/ bionic-security main multiverse restricted universe
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/ bionic-updates main multiverse restricted universe
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/ bionic-backports main multiverse restricted universe
deb-src http://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/ bionic main multiverse restricted universe
deb-src http://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/ bionic-security main multiverse restricted universe
deb-src http://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/ bionic-updates main multiverse restricted universe
deb-src http://mirrors.tuna.tsinghua.edu.cn/ubuntu-ports/ bionic-backports main multiverse restricted universe
Update the software source after switching , Then you can install python3-dev 了 .
Once installed , continue installation onnx:
~:pip3 install onnx==1.6.0
Defaulting to user installation because normal site-packages is not writeable
Looking in indexes: https://pypi.tuna.tsinghua.edu.cn/simple
Collecting onnx==1.6.0
Using cached https://pypi.tuna.tsinghua.edu.cn/packages/81/a9/a14c3bc32908c37b46b19a89eb6185b0c90fd9c03ef12379d51940b8fc71/onnx-1.6.0.t
Requirement already satisfied: protobuf in /home/yaoz/.local/lib/python3.6/site-packages (from onnx==1.6.0) (3.15.6)
Requirement already satisfied: numpy in /home/yaoz/.local/lib/python3.6/site-packages (from onnx==1.6.0) (1.16.1)
Requirement already satisfied: six in /home/yaoz/.local/lib/python3.6/site-packages (from onnx==1.6.0) (1.15.0)
Requirement already satisfied: typing-extensions>=3.6.2.1 in /home/yaoz/.local/lib/python3.6/site-packages (from onnx==1.6.0) (3.7.4.3)
Building wheels for collected packages: onnx
Building wheel for onnx (setup.py) ... done
Created wheel for onnx: filename=onnx-1.6.0-cp36-cp36m-linux_aarch64.whl size=4203662 sha256=152b8bfe50f59264c41d7bd85a7d97710e955172297b9f3da68de98b329634e3
Stored in directory: /home/yaoz/.cache/pip/wheels/cc/b4/8e/7f4b6dabf5070e8c22bdbfe218048484b1cc0745ddf31020f4
Successfully built onnx
Installing collected packages: onnx
Successfully installed onnx-1.6.0
success .
边栏推荐
- 【MobileNet V3】《Searching for MobileNetV3》
- How to clean up logs on notebook computers to improve the response speed of web pages
- 【AutoAugment】《AutoAugment:Learning Augmentation Policies from Data》
- Win10 solves the problem that Internet Explorer cannot be installed
- TimeCLR: A self-supervised contrastive learning framework for univariate time series representation
- 【Cascade FPD】《Deep Convolutional Network Cascade for Facial Point Detection》
- 【Sparse-to-Dense】《Sparse-to-Dense:Depth Prediction from Sparse Depth Samples and a Single Image》
- Thesis tips
- 【MagNet】《Progressive Semantic Segmentation》
- 程序的内存模型
猜你喜欢

PointNet原理证明与理解

将恶意软件嵌入到神经网络中

【BiSeNet】《BiSeNet:Bilateral Segmentation Network for Real-time Semantic Segmentation》

使用百度网盘上传数据到服务器上

传统目标检测笔记1__ Viola Jones

Sorting out dialectics of nature

【Cascade FPD】《Deep Convolutional Network Cascade for Facial Point Detection》

【MobileNet V3】《Searching for MobileNetV3》

Pointnet understanding (step 4 of pointnet Implementation)
![[binocular vision] binocular correction](/img/fe/27fda48c36ca529eec21c631737526.png)
[binocular vision] binocular correction
随机推荐
用全连接层替代掉卷积 -- RepMLP
C#与MySQL数据库连接
Installation and use of image data crawling tool Image Downloader
【Paper Reading】
【Mixup】《Mixup:Beyond Empirical Risk Minimization》
基于onnxruntime的YOLOv5单张图片检测实现
[binocular vision] binocular stereo matching
TimeCLR: A self-supervised contrastive learning framework for univariate time series representation
【Cascade FPD】《Deep Convolutional Network Cascade for Facial Point Detection》
【Random Erasing】《Random Erasing Data Augmentation》
Calculate the difference in days, months, and years between two dates in PHP
Ppt skills
【DIoU】《Distance-IoU Loss:Faster and Better Learning for Bounding Box Regression》
open3d学习笔记四【表面重建】
【MagNet】《Progressive Semantic Segmentation》
Pointnet understanding (step 4 of pointnet Implementation)
Translation of the paper "written mathematical expression recognition with bidirectionally trained transformer"
【Programming】
Apple added the first iPad with lightning interface to the list of retro products
Machine learning theory learning: perceptron