首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >问答首页 >安装CMake时必须安装face_recognition才能生成dlib

安装CMake时必须安装face_recognition才能生成dlib
EN

Stack Overflow用户
提问于 2022-03-01 22:42:52
回答 1查看 2.2K关注 0票数 0

在使用Python3.8.10在Ubuntu20.04上安装face_recognition时,我遇到了这个错误。

代码语言:javascript
运行
复制
ERROR: Failed building wheel for face-recognition-models
  Running setup.py clean for face-recognition-models
Failed to build dlib face-recognition-models
Installing collected packages: Click, numpy, dlib, face-recognition-models, face-recognition
    Running setup.py install for dlib ... error
    ERROR: Command errored out with exit status 1:
     command: '/home/badrelden/Desktop/test python sound/venv/bin/python3' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-tai2snq9/dlib/setup.py'"'"'; __file__='"'"'/tmp/pip-install-tai2snq9/dlib/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-bhy0sde6/install-record.txt --single-version-externally-managed --compile --install-headers '/home/badrelden/Desktop/test python sound/venv/include/site/python3.8/dlib'
         cwd: /tmp/pip-install-tai2snq9/dlib/
    Complete output (8 lines):
    running install
    running build
    running build_py
    package init file 'tools/python/dlib/__init__.py' not found (or not a regular file)
    running build_ext
    
    ERROR: CMake must be installed to build dlib
    
    ----------------------------------------
ERROR: Command errored out with exit status 1: '/home/badrelden/Desktop/test python sound/venv/bin/python3' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-tai2snq9/dlib/setup.py'"'"'; __file__='"'"'/tmp/pip-install-tai2snq9/dlib/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-bhy0sde6/install-record.txt --single-version-externally-managed --compile --install-headers '/home/badrelden/Desktop/test python sound/venv/include/site/python3.8/dlib' Check the logs for full command output.
EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2022-03-01 22:49:03

代码语言:javascript
运行
复制
ERROR: CMake must be installed to build dlib

这是错误消息的关键部分。您需要安装cmake,这可以通过在基于Debian的系统(包括Ubuntu )上运行sudo apt install cmake来完成。安装cmake后,可以重新运行pip install命令。

票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/71315443

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档