GeneFacePlusPlus
GeneFacePlusPlus copied to clipboard
You need C++17 to compile PyTorch
when i run the code install_ext.sh
the error is:
/home/root/anaconda3/envs/gene/lib/python3.9/site-packages/torch/include/c10/util/C++17.h:27:2: error: #error You need C++17 to compile PyTorch
27 | #error You need C++17 to compile PyTorch
/home/root/anaconda3/envs/gene/lib/python3.9/site-packages/torch/include/ATen/core/ivalue_inl.h: In lambda function:
/home/root/anaconda3/envs/gene/lib/python3.9/site-packages/torch/include/ATen/core/ivalue_inl.h:1061:12: warning: ‘if constexpr’ only available with ‘-std=c++17’ or ‘-std=gnu++17’
1061 | if constexpr (::std::is_convertible_v<typename c10::invoke_result_t<T &&, Future&>, IValueWithStorages>) {
| ^~~~~~~~~
/home/root/anaconda3/envs/gene/lib/python3.9/site-packages/torch/include/ATen/core/ivalue_inl.h:1061:30: error: ‘is_convertible_v’ is not a member of ‘std’; did you mean ‘is_convertible’?
1061 | if constexpr (::std::is_convertible_v<typename c10::invoke_result_t<T &&, Future&>, IValueWithStorages>) {
| ^~~~~~~~~~~~~~~~
| is_convertible
/home/root/anaconda3/envs/gene/lib/python3.9/site-packages/torch/include/ATen/core/ivalue_inl.h:1061:91: error: expected ‘(’ before ‘,’ token
1061 | if constexpr (::std::is_convertible_v<typename c10::invoke_result_t<T &&, Future&>, IValueWithStorages>) {
| ^
| (
/home/root/anaconda3/envs/gene/lib/python3.9/site-packages/torch/include/ATen/core/ivalue_inl.h:1061:111: error: expected primary-expression before ‘>’ token
1061 | if constexpr (::std::is_convertible_v<typename c10::invoke_result_t<T &&, Future&>, IValueWithStorages>) {
| ^
/home/root/anaconda3/envs/gene/lib/python3.9/site-packages/torch/include/ATen/core/ivalue_inl.h:1061:112: error: expected primary-expression before ‘)’ token
1061 | if constexpr (::std::is_convertible_v<typename c10::invoke_result_t<T &&, Future&>, IValueWithStorages>) {
| ^
/home/root/anaconda3/envs/gene/lib/python3.9/site-packages/torch/include/ATen/core/ivalue_inl.h:1062:16: warning: structured bindings only available with ‘-std=c++17’ or ‘-std=gnu++17’
1062 | auto [ivalue, storages] = cb(parentFut);
cwd: /home/root/python/genefaceplusplus/modules/radnerfs/raymarching/
Building wheel for raymarching_face (setup.py) ... error
ERROR: Failed building wheel for raymarching_face
Running setup.py clean for raymarching_face
Running command python setup.py clean
running clean
removing 'build/temp.linux-x86_64-cpython-39' (and everything under it)
'build/lib.linux-x86_64-cpython-39' does not exist -- can't clean it
'build/bdist.linux-x86_64' does not exist -- can't clean it
'build/scripts-3.9' does not exist -- can't clean it
removing 'build'
Failed to build raymarching_face
ERROR: Could not build wheels for raymarching_face, which is required to install pyproject.toml-based projects
I install in the WSL ubuntu22.02 envs, need to modify all -std=c++17 to -std=c++14
A Dockerfile with Ubuntu 22.04 is recommended. I've created a PR with dockerfiles. https://github.com/yerfor/GeneFacePlusPlus/pull/63
这对我有用