I'm trying to install dbLib Library for executing python face_recognition as mentioned here
https://github.com/ageitgey/face_recognition/issues/175#issuecomment-355899230
as I execute the command python setup.py install --yes USE_AVX_INSTRUCTIONS
it says the following
C:\Python\dblib\dlib-master>python setup.py install --yes USE_AVX_INSTRUCTIONS -
-yes DLIB_USE_CUDA
running install
running bdist_egg
running build
Detected Python architecture: 32bit
Detected platform: win32
Removing build directory C:\Python\dblib\dlib-master\./tools/python/build
Configuring cmake ...
-- Building for: Visual Studio 14 2015
CMake Error in CMakeLists.txt:
Failed to run MSBuild command:
C:/Program Files (x86)/MSBuild/14.0/bin/MSBuild.exe
to get the value of VCTargetsPath:
Microsoft (R) Build Engine version 14.0.25420.1
Copyright (C) Microsoft Corporation. All rights reserved.
Build started 1/9/2018 12:16:21 AM.
Project "C:\Python\dblib\dlib-master\tools\python\build\CMakeFiles\3.10.0\VC
TargetsPath.vcxproj" on node 1 (default targets).
C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V140\Platforms\Win32\Platf
ormToolsets\v140\Toolset.targets(34,5): error MSB8036: The Windows SDK version 8
.1 was not found. Install the required version of Windows SDK or change the SDK
version in the project property pages or by right-clicking the solution and sele
cting "Retarget solution". [C:\Python\dblib\dlib-master\tools\python\build\CMake
Files\3.10.0\VCTargetsPath.vcxproj]
Done Building Project "C:\Python\dblib\dlib-master\tools\python\build\CMakeF
iles\3.10.0\VCTargetsPath.vcxproj" (default targets) -- FAILED.
Build FAILED.
"C:\Python\dblib\dlib-master\tools\python\build\CMakeFiles\3.10.0\VCTargetsP
ath.vcxproj" (default target) (1) ->
(Desktop_PlatformPrepareForBuild target) ->
C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V140\Platforms\Win32\Pla
tformToolsets\v140\Toolset.targets(34,5): error MSB8036: The Windows SDK version
8.1 was not found. Install the required version of Windows SDK or change the SD
K version in the project property pages or by right-clicking the solution and se
lecting "Retarget solution". [C:\Python\dblib\dlib-master\tools\python\build\CMa
keFiles\3.10.0\VCTargetsPath.vcxproj]
0 Warning(s)
1 Error(s)
Time Elapsed 00:00:00.09
Exit code: 1
-- Configuring incomplete, errors occurred!
See also "C:/Python/dblib/dlib-master/tools/python/build/CMakeFiles/CMakeOutput.
log".
error: cmake configuration failed!
please let me know what I'm doing wrong here
I was able to install it with pip (through the pip install face_recognition command) after I had Boost and CMake installed.
to install face_recognition install Boost from here here and then install Cmake if both get successful then you can directly install it.
and you also need to have visual studio C++ packages to ensure boost work properly
I had the same problem in py charm
face_recognition demands dlib.
dlib demands cmake.
But after you install the cmake its cannot be found, cause cmake is set as a environment variable.
So go at those steps:
this issue may occur due to incorrect versions of cmake and dlib
just type
pip install dlib==19.18 and pip install cmake==3.18.4.post1
Make sure you have Visual Studio installed with C++ packages (C++11 library). Also state exactly the content of Output log file.
I had a lot of trouble for downloading face_recognition in pycharm, but I finally figured it out.
I went to Terminal and typed:
sudo pip install --upgrade pip
sudo pip install cmake
sudo pip install dlib
sudo pip install face_recognition
Just make sure the latest version of pip is installed on your computer and you have CMae installed.
Also, if you are trying to use dlib and/or face_recognition in a pycharm project you can follow the pictures below:
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.