Linux Ubuntu16.04 , Python 3.7.4
pip install dlib
安装会安装失败,报错信息如下:‘ ERROR: Failed building wheel for dlib, subprocess.CalledProcessError: Command '['cmake', '--build', '.', '--config', 'Release', '--', '-j31']' returned non-zero exit status 2.
ERROR: Command errored out with exit status 1: /home/ql/anaconda3/envs/nice/bin/python3.6 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-icbbx6nd/dlib/setup.py'"'"';’
pip install cmake
pip install boost
dlib
tarpython setup.py install
命令来进行安装,报错如下: /home/zengql/zql/project/eight/dlib-19.20.0/dlib/cuda/cuda_dlib.cu(1762):
...
CMake Error at dlib_generated_cuda_dlib.cu.o.Release.cmake:280 (message):
参考链接
# 原始
return std::log1p(std::exp(x));
# 修改成如下
return std::log1pf(std::exp(x));
import dlib
OK.Python 3.7.4 (default, Aug 13 2019, 20:35:49)
[GCC 7.3.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import dlib