如何在windows中下载DLIB,在windows中安装时显示错误。我在运行这个命令之前安装了 Cmake

问题描述 投票:0回答:0

s17cazzf\dlib_37eaaddb525c4de5abb9a93d4033947a uild emp.win-amd64-cpython-310\Release\CMakeFiles .26.0-rc3\VCTargetsPath.vcxproj(15,2):错误 MSB4019:导入的项目“C:\Program Files (x86)\ Microsoft Visual Studio�7\BuildTools\Common7\IDE\VC\VCTargets\Microsoft.Cpp.Default.props”找不到。确认导入声明“C:\Program Files (x86)\Microsoft Visual Studio�7\BuildTools\Common7\IDE\VC\VCTargets\Microsoft.Cpp.Default.props”中的表达式正确,并且该文件存在在磁盘上。 完成构建项目“C:\Users\ADMIN\AppData\Local\Temp\pip-install-s17cazzf\dlib_37eaaddb525c4de5abb9a93d4033947a uild emp.win-amd64-cpython-310\Release\CMakeFiles .26.0-rc3\VCTargetsPath.vcxproj”(默认目标)——失败。

      Build FAILED.

      "C:\Users\ADMIN\AppData\Local\Temp\pip-install-s17cazzf\dlib_37eaaddb525c4de5abb9a93d4033947a\build\temp.win-amd64-cpython-310\Release\CMakeFiles\3.26.0-rc3\VCTargetsPath.vcxproj" (default target) (1) ->
        C:\Users\ADMIN\AppData\Local\Temp\pip-install-s17cazzf\dlib_37eaaddb525c4de5abb9a93d4033947a\build\temp.win-amd64-cpython-310\Release\CMakeFiles\3.26.0-rc3\VCTargetsPath.vcxproj(15,2): error MSB4019: The imported project "C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\IDE\VC\VCTargets\Microsoft.Cpp.Default.props" was not found. Confirm that the expression in the Import declaration "C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\IDE\VC\VCTargets\Microsoft.Cpp.Default.props" is correct, and that the file exists on disk.

          0 Warning(s)
          1 Error(s)

      Time Elapsed 00:00:00.02


    Exit code: 1



  -- Configuring incomplete, errors occurred!
  Traceback (most recent call last):
    File "<string>", line 2, in <module>
    File "<pip-setuptools-caller>", line 34, in <module>
    File "C:\Users\ADMIN\AppData\Local\Temp\pip-install-s17cazzf\dlib_37eaaddb525c4de5abb9a93d4033947a\setup.py", line 222, in <module>
      setup(
    File "C:\Program Files\Python310\lib\site-packages\setuptools\__init__.py", line 108, in setup
      return distutils.core.setup(**attrs)
    File "C:\Program Files\Python310\lib\site-packages\setuptools\_distutils\core.py", line 185, in setup
      return run_commands(dist)
    File "C:\Program Files\Python310\lib\site-packages\setuptools\_distutils\core.py", line 201, in run_commands
      dist.run_commands()
    File "C:\Program Files\Python310\lib\site-packages\setuptools\_distutils\dist.py", line 969, in run_commands
      self.run_command(cmd)
    File "C:\Program Files\Python310\lib\site-packages\setuptools\dist.py", line 1221, in run_command
      super().run_command(command)
    File "C:\Program Files\Python310\lib\site-packages\setuptools\_distutils\dist.py", line 988, in run_command
      cmd_obj.run()
    File "C:\Program Files\Python310\lib\site-packages\wheel\bdist_wheel.py", line 325, in run
      self.run_command("build")
    File "C:\Program Files\Python310\lib\site-packages\setuptools\_distutils\cmd.py", line 318, in run_command
      self.distribution.run_command(command)
    File "C:\Program Files\Python310\lib\site-packages\setuptools\dist.py", line 1221, in run_command
      super().run_command(command)
    File "C:\Program Files\Python310\lib\site-packages\setuptools\_distutils\dist.py", line 988, in run_command
      cmd_obj.run()
    File "C:\Program Files\Python310\lib\site-packages\setuptools\_distutils\command\build.py", line 131, in run
      self.run_command(cmd_name)
    File "C:\Program Files\Python310\lib\site-packages\setuptools\_distutils\cmd.py", line 318, in run_command
      self.distribution.run_command(command)
    File "C:\Program Files\Python310\lib\site-packages\setuptools\dist.py", line 1221, in run_command
      super().run_command(command)
    File "C:\Program Files\Python310\lib\site-packages\setuptools\_distutils\dist.py", line 988, in run_command
      cmd_obj.run()
    File "C:\Users\ADMIN\AppData\Local\Temp\pip-install-s17cazzf\dlib_37eaaddb525c4de5abb9a93d4033947a\setup.py", line 134, in run
      self.build_extension(ext)
    File "C:\Users\ADMIN\AppData\Local\Temp\pip-install-s17cazzf\dlib_37eaaddb525c4de5abb9a93d4033947a\setup.py", line 171, in build_extension
      subprocess.check_call(cmake_setup, cwd=build_folder)
    File "C:\Program Files\Python310\lib\subprocess.py", line 369, in check_call
      raise CalledProcessError(retcode, cmd)
  subprocess.CalledProcessError: Command '['cmake', 'C:\\Users\\ADMIN\\AppData\\Local\\Temp\\pip-install-s17cazzf\\dlib_37eaaddb525c4de5abb9a93d4033947a\\tools\\python', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=C:\\Users\\ADMIN\\AppData\\Local\\Temp\\pip-install-s17cazzf\\dlib_37eaaddb525c4de5abb9a93d4033947a\\build\\lib.win-amd64-cpython-310', '-DPYTHON_EXECUTABLE=C:\\Program Files\\Python310\\python.exe', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE=C:\\Users\\ADMIN\\AppData\\Local\\Temp\\pip-install-s17cazzf\\dlib_37eaaddb525c4de5abb9a93d4033947a\\build\\lib.win-amd64-cpython-310', '-A', 'x64']' returned non-zero exit status 1.
  [end of output]

注意:此错误源自子进程,可能不是 pip 的问题。 错误:dlib 的构建轮失败 为 dlib 运行 setup.py clean 构建 dlib 失败 安装收集的包:dlib 为 dlib 运行 setup.py install ... 错误 错误:子进程因错误而退出

× running setup.py install for dlib 没有运行成功。 │ 退出代码:1 ╰─>【82行输出】 运行安装 C:\Program Files\Python310\lib\site-packages\setuptool

python package dlib
© www.soinside.com 2019 - 2024. All rights reserved.