PS C:\Deepankar\Projects\VaibhavBhaiya-IntruderDetection\PHASE-II> pip install face recognition
Looking in indexes: https://pypi.org/simple, https://pypi.ngc.nvidia.com
Collecting face
Downloading face-22.0.0-py3-none-any.whl (54 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 54.5/54.5 kB 177.1 kB/s eta 0:00:00
ERROR: Could not find a version that satisfies the requirement recognition (from versions: none)
ERROR: No matching distribution found for recognition
[notice] A new release of pip is available: 23.0 -> 23.0.1
[notice] To update, run: python.exe -m pip install --upgrade pip
PS C:\Deepankar\Projects\VaibhavBhaiya-IntruderDetection\PHASE-II> python.exe -m pip install --upgrade pip
Looking in indexes: https://pypi.org/simple, https://pypi.ngc.nvidia.com
Requirement already satisfied: pip in c:\users\deepa\appdata\local\programs\python\python39\lib\site-packages (23.0)
Collecting pip
Downloading pip-23.0.1-py3-none-any.whl (2.1 MB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 2.1/2.1 MB 1.2 MB/s eta 0:00:00
Installing collected packages: pip
Attempting uninstall: pip
Found existing installation: pip 23.0
Uninstalling pip-23.0:
Successfully uninstalled pip-23.0
ERROR: Could not install packages due to an OSError: [WinError 5] Access is denied: 'C:\Users\deepa\AppData\Local\Temp\pip-uninstall-1kkyucgz\pip.exe'
Consider using the --user option or check the permissions.
PS C:\Deepankar\Projects\VaibhavBhaiya-IntruderDetection\PHASE-II> python.exe -m pip install --user --upgrade pip
Looking in indexes: https://pypi.org/simple, https://pypi.ngc.nvidia.com
Requirement already satisfied: pip in c:\users\deepa\appdata\local\programs\python\python39\lib\site-packages (23.0.1)
PS C:\Deepankar\Projects\VaibhavBhaiya-IntruderDetection\PHASE-II> pip install dlib
Looking in indexes: https://pypi.org/simple, https://pypi.ngc.nvidia.com
Collecting dlib
Downloading dlib-19.24.0.tar.gz (3.2 MB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 3.2/3.2 MB 103.2 kB/s eta 0:00:00
Preparing metadata (setup.py) ... done
Building wheels for collected packages: dlib
Building wheel for dlib (setup.py) ... error
error: subprocess-exited-with-error
× python setup.py bdist_wheel did not run successfully.
│ exit code: 1
╰─> [68 lines of output]
running bdist_wheel
running build
running build_py
running build_ext
C:\Users\deepa\AppData\Local\Temp\pip-install-hakhwrt8\dlib_d175b3b197704551a11d650b52da49e5\setup.py:129: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
if LooseVersion(cmake_version) < '3.1.0':
Building extension for Python 3.9.6 (tags/v3.9.6:db3ff76, Jun 28 2021, 15:26:21) [MSC v.1929 64 bit (AMD64)]
Invoking CMake setup: 'cmake C:\Users\deepa\AppData\Local\Temp\pip-install-hakhwrt8\dlib_d175b3b197704551a11d650b52da49e5\tools\python -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=C:\Users\deepa\AppData\Local\Temp\pip-install-hakhwrt8\dlib_d175b3b197704551a11d650b52da49e5\build\lib.win-amd64-cpython-39 -DPYTHON_EXECUTABLE=C:\Users\deepa\AppData\Local\Programs\Python\Python39\python.exe -DCMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE=C:\Users\deepa\AppData\Local\Temp\pip-install-hakhwrt8\dlib_d175b3b197704551a11d650b52da49e5\build\lib.win-amd64-cpython-39 -A x64'
-- Building for: NMake Makefiles
CMake Error at CMakeLists.txt:5 (message):
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
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++.
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-- 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\deepa\AppData\Local\Temp\pip-install-hakhwrt8\dlib_d175b3b197704551a11d650b52da49e5\setup.py", line 222, in <module>
setup(
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\__init__.py", line 87, in setup
return distutils.core.setup(**attrs)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\core.py", line 185, in setup
return run_commands(dist)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\core.py", line 201, in run_commands
dist.run_commands()
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\dist.py", line 969, in run_commands
self.run_command(cmd)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\dist.py", line 1208, in run_command
super().run_command(command)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\dist.py", line 988, in run_command
cmd_obj.run()
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\wheel\bdist_wheel.py", line 325, in run
self.run_command("build")
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\cmd.py", line 318, in run_command
self.distribution.run_command(command)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\dist.py", line 1208, in run_command
super().run_command(command)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\dist.py", line 988, in run_command
cmd_obj.run()
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\command\build.py", line 132, in run
self.run_command(cmd_name)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\cmd.py", line 318, in run_command
self.distribution.run_command(command)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\dist.py", line 1208, in run_command
super().run_command(command)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\dist.py", line 988, in run_command
cmd_obj.run()
File "C:\Users\deepa\AppData\Local\Temp\pip-install-hakhwrt8\dlib_d175b3b197704551a11d650b52da49e5\setup.py", line 134, in run
self.build_extension(ext)
File "C:\Users\deepa\AppData\Local\Temp\pip-install-hakhwrt8\dlib_d175b3b197704551a11d650b52da49e5\setup.py", line 171, in build_extension
subprocess.check_call(cmake_setup, cwd=build_folder)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\subprocess.py", line 373, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['cmake', 'C:\\Users\\deepa\\AppData\\Local\\Temp\\pip-install-hakhwrt8\\dlib_d175b3b197704551a11d650b52da49e5\\tools\\python', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=C:\\Users\\deepa\\AppData\\Local\\Temp\\pip-install-hakhwrt8\\dlib_d175b3b197704551a11d650b52da49e5\\build\\lib.win-amd64-cpython-39', '-DPYTHON_EXECUTABLE=C:\\Users\\deepa\\AppData\\Local\\Programs\\Python\\Python39\\python.exe', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE=C:\\Users\\deepa\\AppData\\Local\\Temp\\pip-install-hakhwrt8\\dlib_d175b3b197704551a11d650b52da49e5\\build\\lib.win-amd64-cpython-39', '-A', 'x64']' returned non-zero exit status 1.
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for dlib
Running setup.py clean for dlib
Failed to build dlib
Installing collected packages: dlib
Running setup.py install for dlib ... error
error: subprocess-exited-with-error
× Running setup.py install for dlib did not run successfully.
│ exit code: 1
╰─> [72 lines of output]
running install
C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\command\install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
warnings.warn(
running build
running build_py
running build_ext
C:\Users\deepa\AppData\Local\Temp\pip-install-hakhwrt8\dlib_d175b3b197704551a11d650b52da49e5\setup.py:129: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
if LooseVersion(cmake_version) < '3.1.0':
Building extension for Python 3.9.6 (tags/v3.9.6:db3ff76, Jun 28 2021, 15:26:21) [MSC v.1929 64 bit (AMD64)]
Invoking CMake setup: 'cmake C:\Users\deepa\AppData\Local\Temp\pip-install-hakhwrt8\dlib_d175b3b197704551a11d650b52da49e5\tools\python -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=C:\Users\deepa\AppData\Local\Temp\pip-install-hakhwrt8\dlib_d175b3b197704551a11d650b52da49e5\build\lib.win-amd64-cpython-39 -DPYTHON_EXECUTABLE=C:\Users\deepa\AppData\Local\Programs\Python\Python39\python.exe -DCMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE=C:\Users\deepa\AppData\Local\Temp\pip-install-hakhwrt8\dlib_d175b3b197704551a11d650b52da49e5\build\lib.win-amd64-cpython-39 -A x64'
-- Building for: NMake Makefiles
CMake Error at CMakeLists.txt:5 (message):
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
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++.
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-- 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\deepa\AppData\Local\Temp\pip-install-hakhwrt8\dlib_d175b3b197704551a11d650b52da49e5\setup.py", line 222, in <module>
setup(
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\__init__.py", line 87, in setup
return distutils.core.setup(**attrs)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\core.py", line 185, in setup
return run_commands(dist)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\core.py", line 201, in run_commands
dist.run_commands()
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\dist.py", line 969, in run_commands
self.run_command(cmd)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\dist.py", line 1208, in run_command
super().run_command(command)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\dist.py", line 988, in run_command
cmd_obj.run()
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\command\install.py", line 68, in run
return orig.install.run(self)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\command\install.py", line 698, in run
self.run_command('build')
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\cmd.py", line 318, in run_command
self.distribution.run_command(command)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\dist.py", line 1208, in run_command
super().run_command(command)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\dist.py", line 988, in run_command
cmd_obj.run()
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\command\build.py", line 132, in run
self.run_command(cmd_name)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\cmd.py", line 318, in run_command
self.distribution.run_command(command)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\dist.py", line 1208, in run_command
super().run_command(command)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\dist.py", line 988, in run_command
cmd_obj.run()
File "C:\Users\deepa\AppData\Local\Temp\pip-install-hakhwrt8\dlib_d175b3b197704551a11d650b52da49e5\setup.py", line 134, in run
self.build_extension(ext)
File "C:\Users\deepa\AppData\Local\Temp\pip-install-hakhwrt8\dlib_d175b3b197704551a11d650b52da49e5\setup.py", line 171, in build_extension
subprocess.check_call(cmake_setup, cwd=build_folder)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\subprocess.py", line 373, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['cmake', 'C:\\Users\\deepa\\AppData\\Local\\Temp\\pip-install-hakhwrt8\\dlib_d175b3b197704551a11d650b52da49e5\\tools\\python', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=C:\\Users\\deepa\\AppData\\Local\\Temp\\pip-install-hakhwrt8\\dlib_d175b3b197704551a11d650b52da49e5\\build\\lib.win-amd64-cpython-39', '-DPYTHON_EXECUTABLE=C:\\Users\\deepa\\AppData\\Local\\Programs\\Python\\Python39\\python.exe', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE=C:\\Users\\deepa\\AppData\\Local\\Temp\\pip-install-hakhwrt8\\dlib_d175b3b197704551a11d650b52da49e5\\build\\lib.win-amd64-cpython-39', '-A', 'x64']' returned non-zero exit status 1.
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: legacy-install-failure
× Encountered error while trying to install package.
╰─> dlib
note: This is an issue with the package mentioned above, not pip.
hint: See above for output from the failure.
PS C:\Deepankar\Projects\VaibhavBhaiya-IntruderDetection\PHASE-II> pip install face-recognition
Looking in indexes: https://pypi.org/simple, https://pypi.ngc.nvidia.com
Collecting face-recognition
Downloading face_recognition-1.3.0-py2.py3-none-any.whl (15 kB)
Requirement already satisfied: numpy in c:\users\deepa\appdata\roaming\python\python39\site-packages (from face-recognition) (1.22.2)
Requirement already satisfied: Click>=6.0 in c:\users\deepa\appdata\roaming\python\python39\site-packages (from face-recognition) (8.0.4)
Requirement already satisfied: Pillow in c:\users\deepa\appdata\roaming\python\python39\site-packages (from face-recognition) (9.0.1)
Collecting dlib>=19.7
Downloading dlib-19.24.0.tar.gz (3.2 MB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 3.2/3.2 MB 160.1 kB/s eta 0:00:00
Preparing metadata (setup.py) ... done
Requirement already satisfied: face-recognition-models>=0.3.0 in c:\users\deepa\appdata\local\programs\python\python39\lib\site-packages (from face-recognition) (0.3.0)
Requirement already satisfied: colorama in c:\users\deepa\appdata\roaming\python\python39\site-packages (from Click>=6.0->face-recognition) (0.4.4)
Building wheels for collected packages: dlib
Building wheel for dlib (setup.py) ... error
error: subprocess-exited-with-error
× python setup.py bdist_wheel did not run successfully.
│ exit code: 1
╰─> [68 lines of output]
running bdist_wheel
running build
running build_py
running build_ext
C:\Users\deepa\AppData\Local\Temp\pip-install-fv7x7lx3\dlib_b7cc73b6dfd4410ea3e6b763453889d8\setup.py:129: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
if LooseVersion(cmake_version) < '3.1.0':
Building extension for Python 3.9.6 (tags/v3.9.6:db3ff76, Jun 28 2021, 15:26:21) [MSC v.1929 64 bit (AMD64)]
Invoking CMake setup: 'cmake C:\Users\deepa\AppData\Local\Temp\pip-install-fv7x7lx3\dlib_b7cc73b6dfd4410ea3e6b763453889d8\tools\python -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=C:\Users\deepa\AppData\Local\Temp\pip-install-fv7x7lx3\dlib_b7cc73b6dfd4410ea3e6b763453889d8\build\lib.win-amd64-cpython-39 -DPYTHON_EXECUTABLE=C:\Users\deepa\AppData\Local\Programs\Python\Python39\python.exe -DCMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE=C:\Users\deepa\AppData\Local\Temp\pip-install-fv7x7lx3\dlib_b7cc73b6dfd4410ea3e6b763453889d8\build\lib.win-amd64-cpython-39 -A x64'
-- Building for: NMake Makefiles
CMake Error at CMakeLists.txt:5 (message):
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
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++.
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-- 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\deepa\AppData\Local\Temp\pip-install-fv7x7lx3\dlib_b7cc73b6dfd4410ea3e6b763453889d8\setup.py", line 222, in <module>
setup(
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\__init__.py", line 87, in setup
return distutils.core.setup(**attrs)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\core.py", line 185, in setup
return run_commands(dist)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\core.py", line 201, in run_commands
dist.run_commands()
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\dist.py", line 969, in run_commands
self.run_command(cmd)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\dist.py", line 1208, in run_command
super().run_command(command)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\dist.py", line 988, in run_command
cmd_obj.run()
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\wheel\bdist_wheel.py", line 325, in run
self.run_command("build")
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\cmd.py", line 318, in run_command
self.distribution.run_command(command)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\dist.py", line 1208, in run_command
super().run_command(command)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\dist.py", line 988, in run_command
cmd_obj.run()
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\command\build.py", line 132, in run
self.run_command(cmd_name)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\cmd.py", line 318, in run_command
self.distribution.run_command(command)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\dist.py", line 1208, in run_command
super().run_command(command)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\dist.py", line 988, in run_command
cmd_obj.run()
File "C:\Users\deepa\AppData\Local\Temp\pip-install-fv7x7lx3\dlib_b7cc73b6dfd4410ea3e6b763453889d8\setup.py", line 134, in run
self.build_extension(ext)
File "C:\Users\deepa\AppData\Local\Temp\pip-install-fv7x7lx3\dlib_b7cc73b6dfd4410ea3e6b763453889d8\setup.py", line 171, in build_extension
subprocess.check_call(cmake_setup, cwd=build_folder)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\subprocess.py", line 373, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['cmake', 'C:\\Users\\deepa\\AppData\\Local\\Temp\\pip-install-fv7x7lx3\\dlib_b7cc73b6dfd4410ea3e6b763453889d8\\tools\\python', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=C:\\Users\\deepa\\AppData\\Local\\Temp\\pip-install-fv7x7lx3\\dlib_b7cc73b6dfd4410ea3e6b763453889d8\\build\\lib.win-amd64-cpython-39', '-DPYTHON_EXECUTABLE=C:\\Users\\deepa\\AppData\\Local\\Programs\\Python\\Python39\\python.exe', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE=C:\\Users\\deepa\\AppData\\Local\\Temp\\pip-install-fv7x7lx3\\dlib_b7cc73b6dfd4410ea3e6b763453889d8\\build\\lib.win-amd64-cpython-39', '-A', 'x64']' returned non-zero exit status 1.
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for dlib
Running setup.py clean for dlib
Failed to build dlib
Installing collected packages: dlib, face-recognition
Running setup.py install for dlib ... error
error: subprocess-exited-with-error
× Running setup.py install for dlib did not run successfully.
│ exit code: 1
╰─> [72 lines of output]
running install
C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\command\install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
warnings.warn(
running build
running build_py
running build_ext
C:\Users\deepa\AppData\Local\Temp\pip-install-fv7x7lx3\dlib_b7cc73b6dfd4410ea3e6b763453889d8\setup.py:129: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
if LooseVersion(cmake_version) < '3.1.0':
Building extension for Python 3.9.6 (tags/v3.9.6:db3ff76, Jun 28 2021, 15:26:21) [MSC v.1929 64 bit (AMD64)]
Invoking CMake setup: 'cmake C:\Users\deepa\AppData\Local\Temp\pip-install-fv7x7lx3\dlib_b7cc73b6dfd4410ea3e6b763453889d8\tools\python -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=C:\Users\deepa\AppData\Local\Temp\pip-install-fv7x7lx3\dlib_b7cc73b6dfd4410ea3e6b763453889d8\build\lib.win-amd64-cpython-39 -DPYTHON_EXECUTABLE=C:\Users\deepa\AppData\Local\Programs\Python\Python39\python.exe -DCMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE=C:\Users\deepa\AppData\Local\Temp\pip-install-fv7x7lx3\dlib_b7cc73b6dfd4410ea3e6b763453889d8\build\lib.win-amd64-cpython-39 -A x64'
-- Building for: NMake Makefiles
CMake Error at CMakeLists.txt:5 (message):
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
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++.
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-- 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\deepa\AppData\Local\Temp\pip-install-fv7x7lx3\dlib_b7cc73b6dfd4410ea3e6b763453889d8\setup.py", line 222, in <module>
setup(
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\__init__.py", line 87, in setup
return distutils.core.setup(**attrs)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\core.py", line 185, in setup
return run_commands(dist)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\core.py", line 201, in run_commands
dist.run_commands()
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\dist.py", line 969, in run_commands
self.run_command(cmd)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\dist.py", line 1208, in run_command
super().run_command(command)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\dist.py", line 988, in run_command
cmd_obj.run()
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\command\install.py", line 68, in run
return orig.install.run(self)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\command\install.py", line 698, in run
self.run_command('build')
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\cmd.py", line 318, in run_command
self.distribution.run_command(command)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\dist.py", line 1208, in run_command
super().run_command(command)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\dist.py", line 988, in run_command
cmd_obj.run()
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\command\build.py", line 132, in run
self.run_command(cmd_name)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\cmd.py", line 318, in run_command
self.distribution.run_command(command)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\dist.py", line 1208, in run_command
super().run_command(command)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\site-packages\setuptools\_distutils\dist.py", line 988, in run_command
cmd_obj.run()
File "C:\Users\deepa\AppData\Local\Temp\pip-install-fv7x7lx3\dlib_b7cc73b6dfd4410ea3e6b763453889d8\setup.py", line 134, in run
self.build_extension(ext)
File "C:\Users\deepa\AppData\Local\Temp\pip-install-fv7x7lx3\dlib_b7cc73b6dfd4410ea3e6b763453889d8\setup.py", line 171, in build_extension
subprocess.check_call(cmake_setup, cwd=build_folder)
File "C:\Users\deepa\AppData\Local\Programs\Python\Python39\lib\subprocess.py", line 373, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['cmake', 'C:\\Users\\deepa\\AppData\\Local\\Temp\\pip-install-fv7x7lx3\\dlib_b7cc73b6dfd4410ea3e6b763453889d8\\tools\\python', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=C:\\Users\\deepa\\AppData\\Local\\Temp\\pip-install-fv7x7lx3\\dlib_b7cc73b6dfd4410ea3e6b763453889d8\\build\\lib.win-amd64-cpython-39', '-DPYTHON_EXECUTABLE=C:\\Users\\deepa\\AppData\\Local\\Programs\\Python\\Python39\\python.exe', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE=C:\\Users\\deepa\\AppData\\Local\\Temp\\pip-install-fv7x7lx3\\dlib_b7cc73b6dfd4410ea3e6b763453889d8\\build\\lib.win-amd64-cpython-39', '-A', 'x64']' returned non-zero exit status 1.
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: legacy-install-failure
× Encountered error while trying to install package.
╰─> dlib
note: This is an issue with the package mentioned above, not pip.
hint: See above for output from the failure.
Trying to install face-recognition
Related
Here the full log of pip3 install lightgbm==3.3.3.
me % pip3 install lightgbm==3.3.3
Collecting lightgbm==3.3.3
Using cached lightgbm-3.3.3.tar.gz (1.5 MB)
Preparing metadata (setup.py) ... done
Requirement already satisfied: wheel in /opt/homebrew/lib/python3.10/site-packages (from lightgbm==3.3.3) (0.37.1)
Collecting numpy
Using cached numpy-1.23.5-cp310-cp310-macosx_11_0_arm64.whl (13.4 MB)
Collecting scipy
Using cached scipy-1.9.3-cp310-cp310-macosx_12_0_arm64.whl (28.5 MB)
Collecting scikit-learn!=0.22.0
Downloading scikit_learn-1.1.3-cp310-cp310-macosx_12_0_arm64.whl (7.7 MB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 7.7/7.7 MB 4.7 MB/s eta 0:00:00
Collecting threadpoolctl>=2.0.0
Downloading threadpoolctl-3.1.0-py3-none-any.whl (14 kB)
Collecting joblib>=1.0.0
Using cached joblib-1.2.0-py3-none-any.whl (297 kB)
Building wheels for collected packages: lightgbm
Building wheel for lightgbm (setup.py) ... error
error: subprocess-exited-with-error
× python setup.py bdist_wheel did not run successfully.
│ exit code: 1
╰─> [86 lines of output]
running bdist_wheel
/opt/homebrew/lib/python3.10/site-packages/setuptools/command/install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
warnings.warn(
running build
running build_py
creating build
creating build/lib
creating build/lib/lightgbm
copying lightgbm/callback.py -> build/lib/lightgbm
copying lightgbm/compat.py -> build/lib/lightgbm
copying lightgbm/plotting.py -> build/lib/lightgbm
copying lightgbm/__init__.py -> build/lib/lightgbm
copying lightgbm/engine.py -> build/lib/lightgbm
copying lightgbm/dask.py -> build/lib/lightgbm
copying lightgbm/basic.py -> build/lib/lightgbm
copying lightgbm/libpath.py -> build/lib/lightgbm
copying lightgbm/sklearn.py -> build/lib/lightgbm
running egg_info
writing lightgbm.egg-info/PKG-INFO
writing dependency_links to lightgbm.egg-info/dependency_links.txt
writing requirements to lightgbm.egg-info/requires.txt
writing top-level names to lightgbm.egg-info/top_level.txt
reading manifest file 'lightgbm.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
no previously-included directories found matching 'build'
warning: no files found matching '*.so' under directory 'lightgbm'
warning: no files found matching '*.so' under directory 'compile'
warning: no files found matching '*.dll' under directory 'compile/Release'
warning: no files found matching '*.dll' under directory 'compile/windows/x64/DLL'
warning: no previously-included files matching '*.py[co]' found anywhere in distribution
warning: no previously-included files found matching 'compile/external_libs/compute/.git'
adding license file 'LICENSE'
writing manifest file 'lightgbm.egg-info/SOURCES.txt'
copying lightgbm/VERSION.txt -> build/lib/lightgbm
installing to build/bdist.macosx-13-arm64/wheel
running install
INFO:LightGBM:Starting to compile the library.
INFO:LightGBM:Starting to compile with CMake.
Traceback (most recent call last):
File "/private/var/folders/qf/7kpp7kws2bs9ljbxdl6vf9480000gn/T/pip-install-qdmnvrdo/lightgbm_7e71affc27c54e8fb3f78d9ef73bd942/setup.py", line 95, in silent_call
subprocess.check_call(cmd, stderr=log, stdout=log)
File "/opt/homebrew/Cellar/python#3.10/3.10.8/Frameworks/Python.framework/Versions/3.10/lib/python3.10/subprocess.py", line 364, in check_call
retcode = call(*popenargs, **kwargs)
File "/opt/homebrew/Cellar/python#3.10/3.10.8/Frameworks/Python.framework/Versions/3.10/lib/python3.10/subprocess.py", line 345, in call
with Popen(*popenargs, **kwargs) as p:
File "/opt/homebrew/Cellar/python#3.10/3.10.8/Frameworks/Python.framework/Versions/3.10/lib/python3.10/subprocess.py", line 971, in __init__
self._execute_child(args, executable, preexec_fn, close_fds,
File "/opt/homebrew/Cellar/python#3.10/3.10.8/Frameworks/Python.framework/Versions/3.10/lib/python3.10/subprocess.py", line 1847, in _execute_child
raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'cmake'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<string>", line 2, in <module>
File "<pip-setuptools-caller>", line 34, in <module>
File "/private/var/folders/qf/7kpp7kws2bs9ljbxdl6vf9480000gn/T/pip-install-qdmnvrdo/lightgbm_7e71affc27c54e8fb3f78d9ef73bd942/setup.py", line 334, in <module>
setup(name='lightgbm',
File "/opt/homebrew/lib/python3.10/site-packages/setuptools/__init__.py", line 87, in setup
return distutils.core.setup(**attrs)
File "/opt/homebrew/lib/python3.10/site-packages/setuptools/_distutils/core.py", line 185, in setup
return run_commands(dist)
File "/opt/homebrew/lib/python3.10/site-packages/setuptools/_distutils/core.py", line 201, in run_commands
dist.run_commands()
File "/opt/homebrew/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 968, in run_commands
self.run_command(cmd)
File "/opt/homebrew/lib/python3.10/site-packages/setuptools/dist.py", line 1217, in run_command
super().run_command(command)
File "/opt/homebrew/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 987, in run_command
cmd_obj.run()
File "/opt/homebrew/lib/python3.10/site-packages/wheel/bdist_wheel.py", line 335, in run
self.run_command('install')
File "/opt/homebrew/lib/python3.10/site-packages/setuptools/_distutils/cmd.py", line 319, in run_command
self.distribution.run_command(command)
File "/opt/homebrew/lib/python3.10/site-packages/setuptools/dist.py", line 1217, in run_command
super().run_command(command)
File "/opt/homebrew/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 987, in run_command
cmd_obj.run()
File "/private/var/folders/qf/7kpp7kws2bs9ljbxdl6vf9480000gn/T/pip-install-qdmnvrdo/lightgbm_7e71affc27c54e8fb3f78d9ef73bd942/setup.py", line 248, in run
compile_cpp(use_mingw=self.mingw, use_gpu=self.gpu, use_cuda=self.cuda, use_mpi=self.mpi,
File "/private/var/folders/qf/7kpp7kws2bs9ljbxdl6vf9480000gn/T/pip-install-qdmnvrdo/lightgbm_7e71affc27c54e8fb3f78d9ef73bd942/setup.py", line 198, in compile_cpp
silent_call(cmake_cmd, raise_error=True, error_msg='Please install CMake and all required dependencies first')
File "/private/var/folders/qf/7kpp7kws2bs9ljbxdl6vf9480000gn/T/pip-install-qdmnvrdo/lightgbm_7e71affc27c54e8fb3f78d9ef73bd942/setup.py", line 99, in silent_call
raise Exception("\n".join((error_msg, LOG_NOTICE)))
Exception: Please install CMake and all required dependencies first
The full version of error log was saved into /Users/me/LightGBM_compilation.log
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for lightgbm
Running setup.py clean for lightgbm
Failed to build lightgbm
Installing collected packages: threadpoolctl, numpy, joblib, scipy, scikit-learn, lightgbm
Running setup.py install for lightgbm ... error
error: subprocess-exited-with-error
× Running setup.py install for lightgbm did not run successfully.
│ exit code: 1
╰─> [45 lines of output]
running install
/opt/homebrew/lib/python3.10/site-packages/setuptools/command/install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
warnings.warn(
INFO:LightGBM:Starting to compile the library.
INFO:LightGBM:Starting to compile with CMake.
Traceback (most recent call last):
File "/private/var/folders/qf/7kpp7kws2bs9ljbxdl6vf9480000gn/T/pip-install-qdmnvrdo/lightgbm_7e71affc27c54e8fb3f78d9ef73bd942/setup.py", line 95, in silent_call
subprocess.check_call(cmd, stderr=log, stdout=log)
File "/opt/homebrew/Cellar/python#3.10/3.10.8/Frameworks/Python.framework/Versions/3.10/lib/python3.10/subprocess.py", line 364, in check_call
retcode = call(*popenargs, **kwargs)
File "/opt/homebrew/Cellar/python#3.10/3.10.8/Frameworks/Python.framework/Versions/3.10/lib/python3.10/subprocess.py", line 345, in call
with Popen(*popenargs, **kwargs) as p:
File "/opt/homebrew/Cellar/python#3.10/3.10.8/Frameworks/Python.framework/Versions/3.10/lib/python3.10/subprocess.py", line 971, in __init__
self._execute_child(args, executable, preexec_fn, close_fds,
File "/opt/homebrew/Cellar/python#3.10/3.10.8/Frameworks/Python.framework/Versions/3.10/lib/python3.10/subprocess.py", line 1847, in _execute_child
raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'cmake'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<string>", line 2, in <module>
File "<pip-setuptools-caller>", line 34, in <module>
File "/private/var/folders/qf/7kpp7kws2bs9ljbxdl6vf9480000gn/T/pip-install-qdmnvrdo/lightgbm_7e71affc27c54e8fb3f78d9ef73bd942/setup.py", line 334, in <module>
setup(name='lightgbm',
File "/opt/homebrew/lib/python3.10/site-packages/setuptools/__init__.py", line 87, in setup
return distutils.core.setup(**attrs)
File "/opt/homebrew/lib/python3.10/site-packages/setuptools/_distutils/core.py", line 185, in setup
return run_commands(dist)
File "/opt/homebrew/lib/python3.10/site-packages/setuptools/_distutils/core.py", line 201, in run_commands
dist.run_commands()
File "/opt/homebrew/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 968, in run_commands
self.run_command(cmd)
File "/opt/homebrew/lib/python3.10/site-packages/setuptools/dist.py", line 1217, in run_command
super().run_command(command)
File "/opt/homebrew/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 987, in run_command
cmd_obj.run()
File "/private/var/folders/qf/7kpp7kws2bs9ljbxdl6vf9480000gn/T/pip-install-qdmnvrdo/lightgbm_7e71affc27c54e8fb3f78d9ef73bd942/setup.py", line 248, in run
compile_cpp(use_mingw=self.mingw, use_gpu=self.gpu, use_cuda=self.cuda, use_mpi=self.mpi,
File "/private/var/folders/qf/7kpp7kws2bs9ljbxdl6vf9480000gn/T/pip-install-qdmnvrdo/lightgbm_7e71affc27c54e8fb3f78d9ef73bd942/setup.py", line 198, in compile_cpp
silent_call(cmake_cmd, raise_error=True, error_msg='Please install CMake and all required dependencies first')
File "/private/var/folders/qf/7kpp7kws2bs9ljbxdl6vf9480000gn/T/pip-install-qdmnvrdo/lightgbm_7e71affc27c54e8fb3f78d9ef73bd942/setup.py", line 99, in silent_call
raise Exception("\n".join((error_msg, LOG_NOTICE)))
Exception: Please install CMake and all required dependencies first
The full version of error log was saved into /Users/me/LightGBM_compilation.log
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: legacy-install-failure
× Encountered error while trying to install package.
╰─> lightgbm
note: This is an issue with the package mentioned above, not pip.
hint: See above for output from the failure.
There is a workaround for this?
When you run pip install lightgbm and see this message in logs:
Building wheels for collected packages: lightgbm
it means that there is not a pre-compiled binary (i.e. wheel) available matching your platform (operating system + architecture + Python version), and that LightGBM needs to be built from source.
lightgbm is a Python package wrapping lib_lightgbm, a C++ library with a C API. So "built from source" for lightgbm means compiling that C/C++ code, which for LightGBM requires:
C and C++ compilers
the CMake build system
an installation of OpenMP
Those components are the "CMake and all required dependencies" referred to in the error message.
On macOS, you should already have a C/C++ compiler installed (clang) by default. To get CMake and OpenMP, run the following.
brew install cmake libomp
NOTE: lightgbm v3.3.3 and older does not support the newest version of OpenMP available as of this writing (v15.x). That was fixed in microsoft/LightGBM#5563. If you end up with OpenMP >=15.0 and lightgbm>=4.0 is not yet available from PyPI, either downgrade OpenMP or build a development version of lightgbm (see "Install from GitHub" in the docs).
I have been trying to download dlib on my system from past one week and I am not able to download it using pip or the manual process I also have looked on several questions asked here and checked the required processes like.
but still, I was unsuccessful ... I need to learn about opencv and dlib so please help me anyone ... and my device properties which I think might not be the problem.
Installed C and C++ compilers and add them to a path.
Installed visual studio 2015 (VS2015) down-loader and 2017 both
Installed all the dependencies through VS2015.(support for C, C++, MS Build, Windows SDK, etc)
C:\Users\Akshay>pip install dlib
Collecting dlib
Using cached https://files.pythonhosted.org/packages/05/57/e8a8caa3c89a27f80bc
78da39c423e2553f482a3705adc619176a3a24b36/dlib-19.17.0.tar.gz
Installing collected packages: dlib
Running setup.py install for dlib ... error
ERROR: Complete output from command 'c:\users\akshay\appdata\local\programs\
python\python37\python.exe' -u -c 'import setuptools, tokenize;__file__='"'"'C:\
\Users\\Akshay\\AppData\\Local\\Temp\\pip-install-8qdv7218\\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 'C:\Users\Akshay\AppData\Local\Temp\pip-record-dupqe8e6\instal
l-record.txt' --single-version-externally-managed --compile:
ERROR: running install
running build
running build_py
package init file 'dlib\__init__.py' not found (or not a regular file)
running build_ext
Building extension for Python 3.7.3 (v3.7.3:ef4ec6ed12, Mar 25 2019, 22:22:0
5) [MSC v.1916 64 bit (AMD64)]
Invoking CMake setup: 'cmake C:\Users\Akshay\AppData\Local\Temp\pip-install-
8qdv7218\dlib\tools\python -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=C:\Users\Akshay\AppD
ata\Local\Temp\pip-install-8qdv7218\dlib\build\lib.win-amd64-3.7 -DPYTHON_EXECUT
ABLE=c:\users\akshay\appdata\local\programs\python\python37\python.exe -DCMAKE_L
IBRARY_OUTPUT_DIRECTORY_RELEASE=C:\Users\Akshay\AppData\Local\Temp\pip-install-8
qdv7218\dlib\build\lib.win-amd64-3.7 -A x64'
-- Building for: NMake Makefiles
CMake Error in CMakeLists.txt:
Generator
NMake Makefiles
does not support platform specification, but platform
x64
was specified.
CMake Error: CMAKE_C_COMPILER not set, after EnableLanguage
CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage
-- Configuring incomplete, errors occurred!
See also "C:/Users/Akshay/AppData/Local/Temp/pip-install-8qdv7218/dlib/build
/temp.win-amd64-3.7/Release/CMakeFiles/CMakeOutput.log".
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "C:\Users\Akshay\AppData\Local\Temp\pip-install-8qdv7218\dlib\setup.p
y", line 261, in <module>
'Topic :: Software Development',
File "c:\users\akshay\appdata\local\programs\python\python37\lib\site-pack
ages\setuptools\__init__.py", line 145, in setup
return distutils.core.setup(**attrs)
File "c:\users\akshay\appdata\local\programs\python\python37\lib\distutils
\core.py", line 148, in setup
dist.run_commands()
File "c:\users\akshay\appdata\local\programs\python\python37\lib\distutils
\dist.py", line 966, in run_commands
self.run_command(cmd)
File "c:\users\akshay\appdata\local\programs\python\python37\lib\distutils
\dist.py", line 985, in run_command
cmd_obj.run()
File "c:\users\akshay\appdata\local\programs\python\python37\lib\site-pack
ages\setuptools\command\install.py", line 61, in run
return orig.install.run(self)
File "c:\users\akshay\appdata\local\programs\python\python37\lib\distutils
\command\install.py", line 545, in run
self.run_command('build')
File "c:\users\akshay\appdata\local\programs\python\python37\lib\distutils
\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "c:\users\akshay\appdata\local\programs\python\python37\lib\distutils
\dist.py", line 985, in run_command
cmd_obj.run()
File "c:\users\akshay\appdata\local\programs\python\python37\lib\distutils
\command\build.py", line 135, in run
self.run_command(cmd_name)
File "c:\users\akshay\appdata\local\programs\python\python37\lib\distutils
\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "c:\users\akshay\appdata\local\programs\python\python37\lib\distutils
\dist.py", line 985, in run_command
cmd_obj.run()
File "C:\Users\Akshay\AppData\Local\Temp\pip-install-8qdv7218\dlib\setup.p
y", line 135, in run
self.build_extension(ext)
File "C:\Users\Akshay\AppData\Local\Temp\pip-install-8qdv7218\dlib\setup.p
y", line 172, in build_extension
subprocess.check_call(cmake_setup, cwd=build_folder)
File "c:\users\akshay\appdata\local\programs\python\python37\lib\subproces
s.py", line 347, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['cmake', 'C:\\Users\\Akshay\\AppDat
a\\Local\\Temp\\pip-install-8qdv7218\\dlib\\tools\\python', '-DCMAKE_LIBRARY_OUT
PUT_DIRECTORY=C:\\Users\\Akshay\\AppData\\Local\\Temp\\pip-install-8qdv7218\\dli
b\\build\\lib.win-amd64-3.7', '-DPYTHON_EXECUTABLE=c:\\users\\akshay\\appdata\\l
ocal\\programs\\python\\python37\\python.exe', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY
_RELEASE=C:\\Users\\Akshay\\AppData\\Local\\Temp\\pip-install-8qdv7218\\dlib\\bu
ild\\lib.win-amd64-3.7', '-A', 'x64']' returned non-zero exit status 1.
----------------------------------------
ERROR: Command "'c:\users\akshay\appdata\local\programs\python\python37\python.e
xe' -u -c 'import setuptools, tokenize;__file__='"'"'C:\\Users\\Akshay\\AppData\
\Local\\Temp\\pip-install-8qdv7218\\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 'C:\Us
ers\Akshay\AppData\Local\Temp\pip-record-dupqe8e6\install-record.txt' --single-v
ersion-externally-managed --compile" failed with error code 1 in C:\Users\Akshay
\AppData\Local\Temp\pip-install-8qdv7218\dlib\
I already have dlib 19.1.0 and open cv 3.4.5 and numpy,scipy packages with advanced version but by using
pip install face_recognition
im getting following errors..Please can anyone help me what i did wrongly..
Collecting face_recognition
Using cached https://files.pythonhosted.org/packages/3f/ed/ad9a28042f373d4633fc8b49109b623597d6f193d3bbbef7780a5ee8eef2/face_recognition-1.2.3-py2.py3-none-any.whl
Requirement already satisfied: numpy in c:\python35\lib\site-packages (from face_recognition) (1.15.4)
Collecting dlib>=19.7 (from face_recognition)
Using cached https://files.pythonhosted.org/packages/35/8d/e4ddf60452e2fb1ce3164f774e68968b3f110f1cb4cd353235d56875799e/dlib-19.16.0.tar.gz
Collecting face-recognition-models>=0.3.0 (from face_recognition)
Requirement already satisfied: Click>=6.0 in c:\python35\lib\site-packages (from face_recognition) (7.0)
Requirement already satisfied: Pillow in c:\python35\lib\site-packages (from face_recognition) (5.4.1)
Building wheels for collected packages: dlib
Running setup.py bdist_wheel for dlib ... error
Complete output from command c:\python35\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\Admin\\AppData\\Local\\Temp\\pip-install-rqlch36v\\dlib\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d C:\Users\Admin\AppData\Local\Temp\pip-wheel-de03y7mf --python-tag cp35:
running bdist_wheel
running build
running build_py
package init file 'dlib\__init__.py' not found (or not a regular file)
running build_ext
Traceback (most recent call last):
File "c:\python35\lib\runpy.py", line 184, in _run_module_as_main
"__main__", mod_spec)
File "c:\python35\lib\runpy.py", line 85, in _run_code
exec(code, run_globals)
File "C:\python35\Scripts\cmake.exe\__main__.py", line 5, in <module>
ImportError: cannot import name 'cmake'
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "C:\Users\Admin\AppData\Local\Temp\pip-install-rqlch36v\dlib\setup.py", line 257, in <module>
'Topic :: Software Development',
File "c:\python35\lib\distutils\core.py", line 148, in setup
dist.run_commands()
File "c:\python35\lib\distutils\dist.py", line 955, in run_commands
self.run_command(cmd)
File "c:\python35\lib\distutils\dist.py", line 974, in run_command
cmd_obj.run()
File "c:\python35\lib\site-packages\wheel\bdist_wheel.py", line 188, in run
self.run_command('build')
File "c:\python35\lib\distutils\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "c:\python35\lib\distutils\dist.py", line 974, in run_command
cmd_obj.run()
File "c:\python35\lib\distutils\command\build.py", line 135, in run
self.run_command(cmd_name)
File "c:\python35\lib\distutils\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "c:\python35\lib\distutils\dist.py", line 974, in run_command
cmd_obj.run()
File "C:\Users\Admin\AppData\Local\Temp\pip-install-rqlch36v\dlib\setup.py", line 127, in run
cmake_version = self.get_cmake_version()
File "C:\Users\Admin\AppData\Local\Temp\pip-install-rqlch36v\dlib\setup.py", line 118, in get_cmake_version
out = subprocess.check_output(['cmake', '--version'])
File "c:\python35\lib\subprocess.py", line 626, in check_output
**kwargs).stdout
File "c:\python35\lib\subprocess.py", line 708, in run
output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command '['cmake', '--version']' returned non-zero exit status 1
----------------------------------------
Failed building wheel for dlib
Running setup.py clean for dlib
Failed to build dlib
Installing collected packages: dlib, face-recognition-models, face-recognition
Found existing installation: dlib 19.1.0
Uninstalling dlib-19.1.0:
Successfully uninstalled dlib-19.1.0
Running setup.py install for dlib ... error
Complete output from command c:\python35\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\Admin\\AppData\\Local\\Temp\\pip-install-rqlch36v\\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 C:\Users\Admin\AppData\Local\Temp\pip-record-tjyw2jml\install-record.txt --single-version-externally-managed --compile:
running install
running build
running build_py
package init file 'dlib\__init__.py' not found (or not a regular file)
running build_ext
Traceback (most recent call last):
File "c:\python35\lib\runpy.py", line 184, in _run_module_as_main
"__main__", mod_spec)
File "c:\python35\lib\runpy.py", line 85, in _run_code
exec(code, run_globals)
File "C:\python35\Scripts\cmake.exe\__main__.py", line 5, in <module>
ImportError: cannot import name 'cmake'
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "C:\Users\Admin\AppData\Local\Temp\pip-install-rqlch36v\dlib\setup.py", line 257, in <module>
'Topic :: Software Development',
File "c:\python35\lib\distutils\core.py", line 148, in setup
dist.run_commands()
File "c:\python35\lib\distutils\dist.py", line 955, in run_commands
self.run_command(cmd)
File "c:\python35\lib\distutils\dist.py", line 974, in run_command
cmd_obj.run()
File "c:\python35\lib\site-packages\setuptools\command\install.py", line 61, in run
return orig.install.run(self)
File "c:\python35\lib\distutils\command\install.py", line 539, in run
self.run_command('build')
File "c:\python35\lib\distutils\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "c:\python35\lib\distutils\dist.py", line 974, in run_command
cmd_obj.run()
File "c:\python35\lib\distutils\command\build.py", line 135, in run
self.run_command(cmd_name)
File "c:\python35\lib\distutils\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "c:\python35\lib\distutils\dist.py", line 974, in run_command
cmd_obj.run()
File "C:\Users\Admin\AppData\Local\Temp\pip-install-rqlch36v\dlib\setup.py", line 127, in run
cmake_version = self.get_cmake_version()
File "C:\Users\Admin\AppData\Local\Temp\pip-install-rqlch36v\dlib\setup.py", line 118, in get_cmake_version
out = subprocess.check_output(['cmake', '--version'])
File "c:\python35\lib\subprocess.py", line 626, in check_output
**kwargs).stdout
File "c:\python35\lib\subprocess.py", line 708, in run
output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command '['cmake', '--version']' returned non-zero exit status 1
----------------------------------------
Rolling back uninstall of dlib
Command "c:\python35\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\Admin\\AppData\\Local\\Temp\\pip-install-rqlch36v\\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 C:\Users\Admin\AppData\Local\Temp\pip-record-tjyw2jml\install-record.txt --single-version-externally-managed --compile" failed with error code 1 in C:\Users\Admin\AppData\Local\Temp\pip-install-rqlch36v\dlib\
Actually i tried with some other installation keywords and tried to rectified error but 'm getting same errors when i used pip install face_recognition and my python version is 3.5.2 and i tried with wheel files also with specified version of python and face_recognition.
Following wheel files are i have tried wheel files..
https://pypi.org/simple/face-recognition/
Hello for this problem make this
step 1:
pip install cmake dlib
step 2:
pip install face-recognition
If you have the problem by dlib check this
sudo apt install python3-dev
i have a problem about building dlib library on my computer which has windows 10 OS.
Here is my python version :
C:\Windows\system32>python --version
Python 3.7.0
Here is my pip version :
C:\Windows\system32>pip --version
pip 10.0.1 from C:\ProgramData\Anaconda3\lib\site-packages\pip (python 3.7)
I am trying to download and build the dlib as below :
pip install --trusted-host pypi.python.org --trusted-host files.pythonhosted.org --trusted-host pypi.org --user dlib
The problem starts when pip finished the downloading. After the downloading completes, I get an error message as below which makes me cannot understand what is the actual problem.
NOTE 1 : I already downloaded Anaconda but it also did not solve my problem.
NOTE 2 : As an advice from some Github pages, i also tried the following command but it gave the same error, unfortunately.
pip install --trusted-host pypi.python.org --trusted-host >files.pythonhosted.org --trusted-host pypi.org --user --no-cache-dir >face_recognition
Downloading https://files.pythonhosted.org/packages/35/8d/e4ddf60452e2fb1ce3164f774e68968b3f110f1cb4cd353235d56875799e/dlib-19.16.0.tar.gz (3.3MB)
100% |████████████████████████████████| 3.3MB 159kB/s
Building wheels for collected packages: dlib
Running setup.py bdist_wheel for dlib ... error
Complete output from command C:\ProgramData\Anaconda3\python.exe -u -c "import setuptools, tokenize;file='C:\Users\arslanom\AppData\Local\Temp\pip-install-2r99u3rh\dlib\setup.py';f=getattr(tokenize, 'open', open)(file);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, file, 'exec'))" bdist_wheel -d C:\Users\arslanom\AppData\Local\Temp\pip-wheel-4nl02lnx --python-tag cp37:
running bdist_wheel
running build
running build_py
package init file 'dlib__init__.py' not found (or not a regular file)
running build_ext
Building extension for Python 3.7.0 (default, Jun 28 2018, 08:04:48) [MSC v.1912 64 bit (AMD64)]
Invoking CMake setup: 'cmake C:\Users\arslanom\AppData\Local\Temp\pip-install-2r99u3rh\dlib\tools\python -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=C:\Users\arslanom\AppData\Local\Temp\pip-install-2r99u3rh\dlib\build\lib.win-amd64-3.7 -DPYTHON_EXECUTABLE=C:\ProgramData\Anaconda3\python.exe -DCMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE=C:\Users\arslanom\AppData\Local\Temp\pip-install-2r99u3rh\dlib\build\lib.win-amd64-3.7 -A x64'
-- Building for: NMake Makefiles
CMake Error in CMakeLists.txt:
Generator
NMake Makefiles
does not support platform specification, but platform
x64
was specified.
CMake Error: CMAKE_C_COMPILER not set, after EnableLanguage
CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage
-- Configuring incomplete, errors occurred!
See also "C:/Users/arslanom/AppData/Local/Temp/pip-install-2r99u3rh/dlib/build/temp.win-amd64-3.7/Release/CMakeFiles/CMakeOutput.log".
Traceback (most recent call last):
File "", line 1, in
File "C:\Users\arslanom\AppData\Local\Temp\pip-install-2r99u3rh\dlib\setup.py", line 257, in
'Topic :: Software Development',
File "C:\ProgramData\Anaconda3\lib\site-packages\setuptools__init__.py", line 140, in setup
return distutils.core.setup(**attrs)
File "C:\ProgramData\Anaconda3\lib\distutils\core.py", line 148, in setup
dist.run_commands()
File "C:\ProgramData\Anaconda3\lib\distutils\dist.py", line 966, in run_commands
self.run_command(cmd)
File "C:\ProgramData\Anaconda3\lib\distutils\dist.py", line 985, in run_command
cmd_obj.run()
File "C:\ProgramData\Anaconda3\lib\site-packages\wheel\bdist_wheel.py", line 202, in run
self.run_command('build')
File "C:\ProgramData\Anaconda3\lib\distutils\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "C:\ProgramData\Anaconda3\lib\distutils\dist.py", line 985, in run_command
cmd_obj.run()
File "C:\ProgramData\Anaconda3\lib\distutils\command\build.py", line 135, in run
self.run_command(cmd_name)
File "C:\ProgramData\Anaconda3\lib\distutils\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "C:\ProgramData\Anaconda3\lib\distutils\dist.py", line 985, in run_command
cmd_obj.run()
File "C:\Users\arslanom\AppData\Local\Temp\pip-install-2r99u3rh\dlib\setup.py", line 133, in run
self.build_extension(ext)
File "C:\Users\arslanom\AppData\Local\Temp\pip-install-2r99u3rh\dlib\setup.py", line 170, in build_extension
subprocess.check_call(cmake_setup, cwd=build_folder)
File "C:\ProgramData\Anaconda3\lib\subprocess.py", line 328, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['cmake', 'C:\Users\arslanom\AppData\Local\Temp\pip-install-2r99u3rh\dlib\tools\python', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=C:\Users\arslanom\AppData\Local\Temp\pip-install-2r99u3rh\dlib\build\lib.win-amd64-3.7', '-DPYTHON_EXECUTABLE=C:\ProgramData\Anaconda3\python.exe', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE=C:\Users\arslanom\AppData\Local\Temp\pip-install-2r99u3rh\dlib\build\lib.win-amd64-3.7', '-A', 'x64']' returned non-zero exit status 1.
Failed building wheel for dlib
Running setup.py clean for dlib
Failed to build dlib
Installing collected packages: dlib
Running setup.py install for dlib ... error
Complete output from command C:\ProgramData\Anaconda3\python.exe -u -c "import setuptools, tokenize;file='C:\Users\arslanom\AppData\Local\Temp\pip-install-2r99u3rh\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 C:\Users\arslanom\AppData\Local\Temp\pip-record-5t8l4109\install-record.txt --single-version-externally-managed --compile --user --prefix=:
running install
running build
running build_py
package init file 'dlib__init__.py' not found (or not a regular file)
running build_ext
Building extension for Python 3.7.0 (default, Jun 28 2018, 08:04:48) [MSC v.1912 64 bit (AMD64)]
Invoking CMake setup: 'cmake C:\Users\arslanom\AppData\Local\Temp\pip-install-2r99u3rh\dlib\tools\python -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=C:\Users\arslanom\AppData\Local\Temp\pip-install-2r99u3rh\dlib\build\lib.win-amd64-3.7 -DPYTHON_EXECUTABLE=C:\ProgramData\Anaconda3\python.exe -DCMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE=C:\Users\arslanom\AppData\Local\Temp\pip-install-2r99u3rh\dlib\build\lib.win-amd64-3.7 -A x64'
-- Building for: NMake Makefiles
CMake Error in CMakeLists.txt:
Generator
NMake Makefiles
does not support platform specification, but platform
x64
was specified.
CMake Error: CMAKE_C_COMPILER not set, after EnableLanguage
CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage
-- Configuring incomplete, errors occurred!
See also "C:/Users/arslanom/AppData/Local/Temp/pip-install-2r99u3rh/dlib/build/temp.win-amd64-3.7/Release/CMakeFiles/CMakeOutput.log".
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "C:\Users\arslanom\AppData\Local\Temp\pip-install-2r99u3rh\dlib\setup.py", line 257, in <module>
'Topic :: Software Development',
File "C:\ProgramData\Anaconda3\lib\site-packages\setuptools\__init__.py", line 140, in setup
return distutils.core.setup(**attrs)
File "C:\ProgramData\Anaconda3\lib\distutils\core.py", line 148, in setup
dist.run_commands()
File "C:\ProgramData\Anaconda3\lib\distutils\dist.py", line 966, in run_commands
self.run_command(cmd)
File "C:\ProgramData\Anaconda3\lib\distutils\dist.py", line 985, in run_command
cmd_obj.run()
File "C:\ProgramData\Anaconda3\lib\site-packages\setuptools\command\install.py", line 61, in run
return orig.install.run(self)
File "C:\ProgramData\Anaconda3\lib\distutils\command\install.py", line 545, in run
self.run_command('build')
File "C:\ProgramData\Anaconda3\lib\distutils\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "C:\ProgramData\Anaconda3\lib\distutils\dist.py", line 985, in run_command
cmd_obj.run()
File "C:\ProgramData\Anaconda3\lib\distutils\command\build.py", line 135, in run
self.run_command(cmd_name)
File "C:\ProgramData\Anaconda3\lib\distutils\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "C:\ProgramData\Anaconda3\lib\distutils\dist.py", line 985, in run_command
cmd_obj.run()
File "C:\Users\arslanom\AppData\Local\Temp\pip-install-2r99u3rh\dlib\setup.py", line 133, in run
self.build_extension(ext)
File "C:\Users\arslanom\AppData\Local\Temp\pip-install-2r99u3rh\dlib\setup.py", line 170, in build_extension
subprocess.check_call(cmake_setup, cwd=build_folder)
File "C:\ProgramData\Anaconda3\lib\subprocess.py", line 328, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['cmake', 'C:\\Users\\arslanom\\AppData\\Local\\Temp\\pip-install-2r99u3rh\\dlib\\tools\\python', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=C:\\Users\\arslanom\\AppData\\Local\\Temp\\pip-install-2r99u3rh\\dlib\\build\\lib.win-amd64-3.7', '-DPYTHON_EXECUTABLE=C:\\ProgramData\\Anaconda3\\python.exe', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE=C:\\Users\\arslanom\\AppData\\Local\\Temp\\pip-install-2r99u3rh\\dlib\\build\\lib.win-amd64-3.7', '-A', 'x64']' returned non-zero exit status 1.
Failed building wheels means that, naively dlib is constructed on c++. Soo for it to be converted to python you'll need Microsoft visual studio c++ package to build the wheel files
Below steps I used to install Dlib on Windows:
Pre-Requisite:
1) Install Python 3.6 64-bit. If you have Python 32-bit, you need to install Python 3.6 64-bit. Please note, you can not have both Python versions running at same time. If you are intended to run Python 3.6 64-bit, then you need keep Python 3.6 library paths at first position in System and User environment paths.
Visit this tutorial for more info on switching between python versions: Tutorial on switching between Python Versions
2) Install cmake library:
Click link – Cmake Installer and install Cmake. Otherwise, open CMD: install cmake library using pip: pip install cmake
Give path of cmake library in System Environment Path and User Path.
e.g. C:\Program Files\CMake\bin
In your case it could be different.
3) Install Visual Studio C++ Build Tools:
Follow this tutorial to install C++ build tools: Tutorial to install C++ Build Tools
It is essential to install C++ compiler to install dlib library
4) Install Numpy library: pip install numpy
After successful installation of above libraries/tools, open CMD with “Run as Administrator”. Then give command “pip install dlib”
It will install dlib library and it will take time to install. If you have some previous versions of dlib then uninstall them first.
Be patient as it takes lot of time to install this library and also many other ML libraries.
I successfully installed dlib 19.8.1 on Python 3.7 for windows 64bit using
https://www.file-upload.com/qsd69ajuqr2i
I have faced these problems too. You need to install Python 3.6 or 3.7 .
Before that you have to install cmake and set up visual studio as c++ desktop development then install dlib
I'm relatively new to Python, Django and Heroku. I'm attempting to follow the instructions on setting up a Django Heroku project found here. I'm getting stuck at the following command:
$ pip install django-toolbelt
I get the following error
Requirement already satisfied (use --upgrade to upgrade): django-toolbelt in c:\
django\contactmanager\venv\lib\site-packages
Requirement already satisfied (use --upgrade to upgrade): django in c:\django\co
ntactmanager\venv\lib\site-packages (from django-toolbelt)
Downloading/unpacking psycopg2 (from django-toolbelt)
Running setup.py egg_info for package psycopg2
Downloading/unpacking gunicorn (from django-toolbelt)
Running setup.py egg_info for package gunicorn
warning: no previously-included files matching '*.pyc' found under directory
'docs'
warning: no previously-included files matching '*.pyo' found under directory
'docs'
warning: no previously-included files matching '*.pyc' found under directory
'tests'
warning: no previously-included files matching '*.pyo' found under directory
'tests'
warning: no previously-included files matching '*.pyc' found under directory
'examples'
warning: no previously-included files matching '*.pyo' found under directory
'examples'
Downloading/unpacking dj-database-url (from django-toolbelt)
Running setup.py egg_info for package dj-database-url
Downloading/unpacking dj-static (from django-toolbelt)
Running setup.py egg_info for package dj-static
Downloading/unpacking static (from dj-static->django-toolbelt)
Running setup.py egg_info for package static
Downloading/unpacking pystache (from static->dj-static->django-toolbelt)
Running setup.py egg_info for package pystache
pystache: using: version '0.6' of <module 'setuptools' from 'C:\Django\conta
ctmanager\venv\lib\site-packages\distribute-0.6.34-py2.7.egg\setuptools\__init__
.pyc'>
Installing collected packages: psycopg2, gunicorn, dj-database-url, dj-static, s
tatic, pystache
Running setup.py install for psycopg2
building 'psycopg2._psycopg' extension
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "C:\Django\contactmanager\venv\build\psycopg2\setup.py", line 568, in
<module>
ext_modules=ext)
File "C:\Python27\Lib\distutils\core.py", line 152, in setup
dist.run_commands()
File "C:\Python27\Lib\distutils\dist.py", line 953, in run_commands
self.run_command(cmd)
File "C:\Python27\Lib\distutils\dist.py", line 972, in run_command
cmd_obj.run()
File "C:\Django\contactmanager\venv\lib\site-packages\distribute-0.6.34-py
2.7.egg\setuptools\command\install.py", line 53, in run
return _install.run(self)
File "C:\Python27\Lib\distutils\command\install.py", line 563, in run
self.run_command('build')
File "C:\Python27\Lib\distutils\cmd.py", line 326, in run_command
self.distribution.run_command(command)
File "C:\Python27\Lib\distutils\dist.py", line 972, in run_command
cmd_obj.run()
File "C:\Python27\Lib\distutils\command\build.py", line 127, in run
self.run_command(cmd_name)
File "C:\Python27\Lib\distutils\cmd.py", line 326, in run_command
self.distribution.run_command(command)
File "C:\Python27\Lib\distutils\dist.py", line 972, in run_command
cmd_obj.run()
File "C:\Python27\Lib\distutils\command\build_ext.py", line 337, in run
self.build_extensions()
File "C:\Python27\Lib\distutils\command\build_ext.py", line 446, in build_
extensions
self.build_extension(ext)
File "C:\Django\contactmanager\venv\build\psycopg2\setup.py", line 284, in
build_extension
build_ext.build_extension(self, extension)
File "C:\Python27\Lib\distutils\command\build_ext.py", line 496, in build_
extension
depends=ext.depends)
File "C:\Python27\Lib\distutils\msvc9compiler.py", line 473, in compile
self.initialize()
File "C:\Python27\Lib\distutils\msvc9compiler.py", line 383, in initialize
vc_env = query_vcvarsall(VERSION, plat_spec)
File "C:\Python27\Lib\distutils\msvc9compiler.py", line 299, in query_vcva
rsall
raise ValueError(str(list(result.keys())))
ValueError: [u'path']
Complete output from command C:\Django\contactmanager\venv\Scripts\python.ex
e -c "import setuptools;__file__='C:\\Django\\contactmanager\\venv\\build\\psyco
pg2\\setup.py';exec(compile(open(__file__).read().replace('\r\n', '\n'), __file_
_, 'exec'))" install --record c:\users\hp\appdata\local\temp\pip-ka3mfj-record\i
nstall-record.txt --single-version-externally-managed --install-headers C:\Djang
o\contactmanager\venv\include\site\python2.7:
running install
running build
running build_py
running build_ext
building 'psycopg2._psycopg' extension
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "C:\Django\contactmanager\venv\build\psycopg2\setup.py", line 568, in <mo
dule>
ext_modules=ext)
File "C:\Python27\Lib\distutils\core.py", line 152, in setup
dist.run_commands()
File "C:\Python27\Lib\distutils\dist.py", line 953, in run_commands
self.run_command(cmd)
File "C:\Python27\Lib\distutils\dist.py", line 972, in run_command
cmd_obj.run()
File "C:\Django\contactmanager\venv\lib\site-packages\distribute-0.6.34-py2.7.
egg\setuptools\command\install.py", line 53, in run
return _install.run(self)
File "C:\Python27\Lib\distutils\command\install.py", line 563, in run
self.run_command('build')
File "C:\Python27\Lib\distutils\cmd.py", line 326, in run_command
self.distribution.run_command(command)
File "C:\Python27\Lib\distutils\dist.py", line 972, in run_command
cmd_obj.run()
File "C:\Python27\Lib\distutils\command\build.py", line 127, in run
self.run_command(cmd_name)
File "C:\Python27\Lib\distutils\cmd.py", line 326, in run_command
self.distribution.run_command(command)
File "C:\Python27\Lib\distutils\dist.py", line 972, in run_command
cmd_obj.run()
File "C:\Python27\Lib\distutils\command\build_ext.py", line 337, in run
self.build_extensions()
File "C:\Python27\Lib\distutils\command\build_ext.py", line 446, in build_exte
nsions
self.build_extension(ext)
File "C:\Django\contactmanager\venv\build\psycopg2\setup.py", line 284, in bui
ld_extension
build_ext.build_extension(self, extension)
File "C:\Python27\Lib\distutils\command\build_ext.py", line 496, in build_exte
nsion
depends=ext.depends)
File "C:\Python27\Lib\distutils\msvc9compiler.py", line 473, in compile
self.initialize()
File "C:\Python27\Lib\distutils\msvc9compiler.py", line 383, in initialize
vc_env = query_vcvarsall(VERSION, plat_spec)
File "C:\Python27\Lib\distutils\msvc9compiler.py", line 299, in query_vcvarsal
l
raise ValueError(str(list(result.keys())))
ValueError: [u'path']
----------------------------------------
Command C:\Django\contactmanager\venv\Scripts\python.exe -c "import setuptools;_
_file__='C:\\Django\\contactmanager\\venv\\build\\psycopg2\\setup.py';exec(compi
le(open(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --re
cord c:\users\hp\appdata\local\temp\pip-ka3mfj-record\install-record.txt --singl
e-version-externally-managed --install-headers C:\Django\contactmanager\venv\inc
lude\site\python2.7 failed with error code 1 in C:\Django\contactmanager\venv\bu
ild\psycopg2
Storing complete log in C:\Users\hp\pip\pip.log
According to this link I'm supposed to install python-dev, python-psycopg2, libpq-dev before installing django-toolbelt.
I'm on a Windows machine. How can I install these dependencies? I tried installing them with pip but that doesn't work.
Apparently psycopg2 installers do not work under a virtualenv environment. I downloaded an executable binary from http://stickpeople.com/projects/python/win-psycopg/
To install the native binary in a virtual envrionment, use easy_install:
C:\virtualenv\Scripts\> activate.bat
(virtualenv) C:\virtualenv\Scripts\> easy_install psycopg2-2.5.win32-py2.7-pg9.2.4-release.exe
This blog post seems useful for your case:
http://www.swarley.me.uk/blog/2014/02/24/create-a-django-development-environment-on-64-bit-windows-for-heroku-deployment/
Or you can just find the windows ports for these dependency packages.