在安装人脸识别和dlib时遇到错误



我尝试安装dlib文件,我得到这个错误:

cd C:UsersDnyaneshwarAppDataLocalProgramsPythonPython311Libsite-packages
PS C:UsersDnyaneshwarAppDataLocalProgramsPythonPython311Libsite-packages> python setup.py install
You must use Visual Studio to build a python extension on windows.  If you
are getting this error it means you have not installed Visual C++.  Note
that there are many flavors of Visual Studio, like Visual Studio for C#
development.  You need to install Visual Studio for C++.
subprocess.check_call(cmake_setup, cwd=build_folder)
File "C:UsersDnyaneshwarAppDataLocalProgramsPythonPython311Libsubprocess.py", line 413, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['cmake', 'C:\Users\Dnyaneshwar\AppData\Local\Programs\Python\Python311\Lib\site-packages\tools\python', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=C:\Users\Dnyaneshwar\AppData\Local\Programs\Python\Python311\Lib\site-packages\build\lib.win-amd64-cpython-311', '-DPYTHON_EXECUTABLE=C:\Users\Dnyaneshwar\AppData\Local\Programs\Python\Python311\python.exe', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE=C:\Users\Dnyaneshwar\AppData\Local\Programs\Python\Python311\Lib\site-packages\build\lib.win-amd64-cpython-311', '-A', 'x64']' returned non-zero exit status 1.

我已经为windows安装了c++ CMake工具,但我仍然得到这个错误。

我不得不将python从3.11降级到3.9现在它工作了

相关内容

  • 没有找到相关文章

最新更新