installation error while downloading dlib file - python

I am trying to download dlib module in python version 3.8.3
My pip version is 22.1
This is the error I got while I was trying to double the dlib module on my system-
Using cached dlib-19.24.0.tar.gz (3.2 MB)
Preparing metadata (setup.py) ... done
Using legacy 'setup.py install' for dlib, since package 'wheel' is not installed.
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
╰─> [61 lines of output]
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
Building extension for Python 3.8.3 (tags/v3.8.3:6f8c832, May 13 2020, 22:37:02) [MSC v.1924 64 bit (AMD64)]
Invoking CMake setup: 'cmake C:\Users\user\AppData\Local\Temp\pip-install-7w8dbl2a\dlib_a6e65f9bc04843d0890216847fb50eca\tools\python -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=C:\Users\user\AppData\Local\Temp\pip-install-7w8dbl2a\dlib_a6e65f9bc04843d0890216847fb50eca\build\lib.win-amd64-3.8 -DPYTHON_EXECUTABLE=c:\users\user\appdata\local\programs\python\python38\python.exe -DCMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE=C:\Users\user\AppData\Local\Temp\pip-install-7w8dbl2a\dlib_a6e65f9bc04843d0890216847fb50eca\build\lib.win-amd64-3.8 -A x64'
-- Building for: NMake Makefiles
CMake Error at CMakeLists.txt:5 (message):
-- 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\user\AppData\Local\Temp\pip-install-7w8dbl2a\dlib_a6e65f9bc04843d0890216847fb50eca\setup.py", line 222, in <module>
setup(
File "c:\users\user\appdata\local\programs\python\python38\lib\site-packages\setuptools\__init__.py", line 145, in setup
return distutils.core.setup(**attrs)
File "c:\users\user\appdata\local\programs\python\python38\lib\distutils\core.py", line 148, in setup
dist.run_commands()
File "c:\users\user\appdata\local\programs\python\python38\lib\distutils\dist.py", line 966, in run_commands
self.run_command(cmd)
File "c:\users\user\appdata\local\programs\python\python38\lib\distutils\dist.py", line 985, in run_command
cmd_obj.run()
File "c:\users\user\appdata\local\programs\python\python38\lib\site-packages\setuptools\command\install.py", line 61, in run
return orig.install.run(self)
File "c:\users\user\appdata\local\programs\python\python38\lib\distutils\command\install.py", line 545, in run
self.run_command('build')
File "c:\users\user\appdata\local\programs\python\python38\lib\distutils\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "c:\users\user\appdata\local\programs\python\python38\lib\distutils\dist.py", line 985, in run_command
cmd_obj.run()
File "c:\users\user\appdata\local\programs\python\python38\lib\distutils\command\build.py", line 135, in run
self.run_command(cmd_name)
File "c:\users\user\appdata\local\programs\python\python38\lib\distutils\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "c:\users\user\appdata\local\programs\python\python38\lib\distutils\dist.py", line 985, in run_command
cmd_obj.run()
File "C:\Users\user\AppData\Local\Temp\pip-install-7w8dbl2a\dlib_a6e65f9bc04843d0890216847fb50eca\setup.py", line 134, in run
self.build_extension(ext)
File "C:\Users\user\AppData\Local\Temp\pip-install-7w8dbl2a\dlib_a6e65f9bc04843d0890216847fb50eca\setup.py", line 171, in build_extension
subprocess.check_call(cmake_setup, cwd=build_folder)
File "c:\users\user\appdata\local\programs\python\python38\lib\subprocess.py", line 364, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['cmake', 'C:\\Users\\user\\AppData\\Local\\Temp\\pip-install-7w8dbl2a\\dlib_a6e65f9bc04843d0890216847fb50eca\\tools\\python', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=C:\\Users\\user\\AppData\\Local\\Temp\\pip-install-7w8dbl2a\\dlib_a6e65f9bc04843d0890216847fb50eca\\build\\lib.win-amd64-3.8', '-DPYTHON_EXECUTABLE=c:\\users\\user\\appdata\\local\\programs\\python\\python38\\python.exe', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE=C:\\Users\\user\\AppData\\Local\\Temp\\pip-install-7w8dbl2a\\dlib_a6e65f9bc04843d0890216847fb50eca\\build\\lib.win-amd64-3.8', '-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
The pip version also shows that the error is in installation and not in pip. I didn't include it in the error code because it became too long.
How can I fix this error ?

Related

cmake instaled but dlib not on pycharm

+++++++++++after i instaled c make +++++++
that shows like:
C:\Users\Medivh>pip install cmake
Collecting cmake
Using cached cmake-3.25.2-py2.py3-none-win_amd64.whl (32.6 MB)
Installing collected packages: cmake
Successfully installed cmake-3.25.2
+++++++++++++i am trying to instal dlib+++++++
C:\Users\Medivh>pip install dlib
Collecting dlib
Using cached dlib-19.24.0.tar.gz (3.2 MB)
Preparing metadata (setup.py) ... done
Installing collected packages: dlib
DEPRECATION: dlib is being installed using the legacy 'setup.py install' method, because it does not have a 'pyproject.toml' and the 'wheel' package is not installed. pip 23.1 will enforce this behaviour change. A possible replacement is to enable the '--use-pep517' option. Discussion can be found at https://github.com/pypa/pip/issues/8559
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\Medivh\AppData\Local\Programs\Python\Python311\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\Medivh\AppData\Local\Temp\pip-install-9fdav4gi\dlib_911fc39286d44de494eee64b175fb2f2\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.11.0 (main, Oct 24 2022, 18:26:48) [MSC v.1933 64 bit (AMD64)]
Invoking CMake setup: 'cmake C:\Users\Medivh\AppData\Local\Temp\pip-install-9fdav4gi\dlib_911fc39286d44de494eee64b175fb2f2\tools\python -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=C:\Users\Medivh\AppData\Local\Temp\pip-install-9fdav4gi\dlib_911fc39286d44de494eee64b175fb2f2\build\lib.win-amd64-cpython-311 -DPYTHON_EXECUTABLE=C:\Users\Medivh\AppData\Local\Programs\Python\Python311\python.exe -DCMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE=C:\Users\Medivh\AppData\Local\Temp\pip-install-9fdav4gi\dlib_911fc39286d44de494eee64b175fb2f2\build\lib.win-amd64-cpython-311 -A x64'
-- Building for: Visual Studio 17 2022
-- Selecting Windows SDK version to target Windows 10.0.19044.
-- The C compiler identification is unknown
-- The CXX compiler identification is unknown
CMake Error at CMakeLists.txt:14 (project):
No CMAKE_C_COMPILER could be found.
CMake Error at CMakeLists.txt:14 (project):
No CMAKE_CXX_COMPILER could be found.
-- Configuring incomplete, errors occurred!
See also "C:/Users/Medivh/AppData/Local/Temp/pip-install-9fdav4gi/dlib_911fc39286d44de494eee64b175fb2f2/build/temp.win-amd64-cpython-311/Release/CMakeFiles/CMakeOutput.log".
See also "C:/Users/Medivh/AppData/Local/Temp/pip-install-9fdav4gi/dlib_911fc39286d44de494eee64b175fb2f2/build/temp.win-amd64-cpython-311/Release/CMakeFiles/CMakeError.log".
Traceback (most recent call last):
File "<string>", line 2, in <module>
File "<pip-setuptools-caller>", line 34, in <module>
File "C:\Users\Medivh\AppData\Local\Temp\pip-install-9fdav4gi\dlib_911fc39286d44de494eee64b175fb2f2\setup.py", line 222, in <module>
setup(
File "C:\Users\Medivh\AppData\Local\Programs\Python\Python311\Lib\site-packages\setuptools\__init__.py", line 87, in setup
return distutils.core.setup(**attrs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Medivh\AppData\Local\Programs\Python\Python311\Lib\site-packages\setuptools\_distutils\core.py", line 185, in setup
return run_commands(dist)
^^^^^^^^^^^^^^^^^^
File "C:\Users\Medivh\AppData\Local\Programs\Python\Python311\Lib\site-packages\setuptools\_distutils\core.py", line 201, in run_commands
dist.run_commands()
File "C:\Users\Medivh\AppData\Local\Programs\Python\Python311\Lib\site-packages\setuptools\_distutils\dist.py", line 968, in run_commands
self.run_command(cmd)
File "C:\Users\Medivh\AppData\Local\Programs\Python\Python311\Lib\site-packages\setuptools\dist.py", line 1217, in run_command
super().run_command(command)
File "C:\Users\Medivh\AppData\Local\Programs\Python\Python311\Lib\site-packages\setuptools\_distutils\dist.py", line 987, in run_command
cmd_obj.run()
File "C:\Users\Medivh\AppData\Local\Programs\Python\Python311\Lib\site-packages\setuptools\command\install.py", line 68, in run
return orig.install.run(self)
^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Medivh\AppData\Local\Programs\Python\Python311\Lib\site-packages\setuptools\_distutils\command\install.py", line 698, in run
self.run_command('build')
File "C:\Users\Medivh\AppData\Local\Programs\Python\Python311\Lib\site-packages\setuptools\_distutils\cmd.py", line 319, in run_command
self.distribution.run_command(command)
File "C:\Users\Medivh\AppData\Local\Programs\Python\Python311\Lib\site-packages\setuptools\dist.py", line 1217, in run_command
super().run_command(command)
File "C:\Users\Medivh\AppData\Local\Programs\Python\Python311\Lib\site-packages\setuptools\_distutils\dist.py", line 987, in run_command
cmd_obj.run()
File "C:\Users\Medivh\AppData\Local\Programs\Python\Python311\Lib\site-packages\setuptools\_distutils\command\build.py", line 132, in run
self.run_command(cmd_name)
File "C:\Users\Medivh\AppData\Local\Programs\Python\Python311\Lib\site-packages\setuptools\_distutils\cmd.py", line 319, in run_command
self.distribution.run_command(command)
File "C:\Users\Medivh\AppData\Local\Programs\Python\Python311\Lib\site-packages\setuptools\dist.py", line 1217, in run_command
super().run_command(command)
File "C:\Users\Medivh\AppData\Local\Programs\Python\Python311\Lib\site-packages\setuptools\_distutils\dist.py", line 987, in run_command
cmd_obj.run()
File "C:\Users\Medivh\AppData\Local\Temp\pip-install-9fdav4gi\dlib_911fc39286d44de494eee64b175fb2f2\setup.py", line 134, in run
self.build_extension(ext)
File "C:\Users\Medivh\AppData\Local\Temp\pip-install-9fdav4gi\dlib_911fc39286d44de494eee64b175fb2f2\setup.py", line 171, in build_extension
subprocess.check_call(cmake_setup, cwd=build_folder)
File "C:\Users\Medivh\AppData\Local\Programs\Python\Python311\Lib\subprocess.py", line 413, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['cmake', 'C:\\Users\\Medivh\\AppData\\Local\\Temp\\pip-install-9fdav4gi\\dlib_911fc39286d44de494eee64b175fb2f2\\tools\\python', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=C:\\Users\\Medivh\\AppData\\Local\\Temp\\pip-install-9fdav4gi\\dlib_911fc39286d44de494eee64b175fb2f2\\build\\lib.win-amd64-cpython-311', '-DPYTHON_EXECUTABLE=C:\\Users\\Medivh\\AppData\\Local\\Programs\\Python\\Python311\\python.exe', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE=C:\\Users\\Medivh\\AppData\\Local\\Temp\\pip-install-9fdav4gi\\dlib_911fc39286d44de494eee64b175fb2f2\\build\\lib.win-amd64-cpython-311', '-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.
i am try to install face_recognition but dlib error stand on my way
how i fix this problem
my python versioon is 3.11
and windows 10 64 bit

dlib python not install on a wss

hi i am try to install dlib on a wss using pip but its giving me this error
Collecting dlib
Using cached dlib-19.24.0.tar.gz (3.2 MB)
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
╰─> [44 lines of output]
running bdist_wheel
running build
running build_py
package init file 'tools/python/dlib/__init__.py' not found (or not a regular file)
running build_ext
Building extension for Python 3.8.10 (default, Nov 26 2021, 20:14:08)
Invoking CMake setup: 'cmake /tmp/pip-install-6l9ppgj8/dlib_a9ff28b611c041e7822ffaa612e7c30a/tools/python -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=/tmp/pip-install-6l9ppgj8/dlib_a9ff28b611c041e7822ffaa612e7c30a/build/lib.linux-x86_64-3.8 -DPYTHON_EXECUTABLE=/usr/bin/python3 -DCMAKE_BUILD_TYPE=Release'
CMake Error: CMake was unable to find a build program corresponding to "Unix Makefiles". CMAKE_MAKE_PROGRAM is not set. You probably need to select a different build tool.
CMake Error: CMAKE_C_COMPILER not set, after EnableLanguage
CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage
-- Configuring incomplete, errors occurred!
See also "/tmp/pip-install-6l9ppgj8/dlib_a9ff28b611c041e7822ffaa612e7c30a/build/temp.linux-x86_64-3.8/CMakeFiles/CMakeOutput.log".
Traceback (most recent call last):
File "<string>", line 2, in <module>
File "<pip-setuptools-caller>", line 34, in <module>
File "/tmp/pip-install-6l9ppgj8/dlib_a9ff28b611c041e7822ffaa612e7c30a/setup.py", line 222, in <module>
setup(
File "/usr/lib/python3/dist-packages/setuptools/__init__.py", line 144, in setup
return distutils.core.setup(**attrs)
File "/usr/lib/python3.8/distutils/core.py", line 148, in setup
dist.run_commands()
File "/usr/lib/python3.8/distutils/dist.py", line 966, in run_commands
self.run_command(cmd)
File "/usr/lib/python3.8/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/home/zain/.local/lib/python3.8/site-packages/wheel/bdist_wheel.py", line 299, in run
self.run_command('build')
File "/usr/lib/python3.8/distutils/cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "/usr/lib/python3.8/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/usr/lib/python3.8/distutils/command/build.py", line 135, in run
self.run_command(cmd_name)
File "/usr/lib/python3.8/distutils/cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "/usr/lib/python3.8/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/tmp/pip-install-6l9ppgj8/dlib_a9ff28b611c041e7822ffaa612e7c30a/setup.py", line 134, in run
self.build_extension(ext)
File "/tmp/pip-install-6l9ppgj8/dlib_a9ff28b611c041e7822ffaa612e7c30a/setup.py", line 171, in build_extension
subprocess.check_call(cmake_setup, cwd=build_folder)
File "/usr/lib/python3.8/subprocess.py", line 364, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['cmake', '/tmp/pip-install-6l9ppgj8/dlib_a9ff28b611c041e7822ffaa612e7c30a/tools/python', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=/tmp/pip-install-6l9ppgj8/dlib_a9ff28b611c041e7822ffaa612e7c30a/build/lib.linux-x86_64-3.8', '-DPYTHON_EXECUTABLE=/usr/bin/python3', '-DCMAKE_BUILD_TYPE=Release']' 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
╰─> [46 lines of output]
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
Building extension for Python 3.8.10 (default, Nov 26 2021, 20:14:08)
Invoking CMake setup: 'cmake /tmp/pip-install-6l9ppgj8/dlib_a9ff28b611c041e7822ffaa612e7c30a/tools/python -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=/tmp/pip-install-6l9ppgj8/dlib_a9ff28b611c041e7822ffaa612e7c30a/build/lib.linux-x86_64-3.8 -DPYTHON_EXECUTABLE=/usr/bin/python3 -DCMAKE_BUILD_TYPE=Release'
CMake Error: CMake was unable to find a build program corresponding to "Unix Makefiles". CMAKE_MAKE_PROGRAM is not set. You probably need to select a different build tool.
CMake Error: CMAKE_C_COMPILER not set, after EnableLanguage
CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage
-- Configuring incomplete, errors occurred!
See also "/tmp/pip-install-6l9ppgj8/dlib_a9ff28b611c041e7822ffaa612e7c30a/build/temp.linux-x86_64-3.8/CMakeFiles/CMakeOutput.log".
Traceback (most recent call last):
File "<string>", line 2, in <module>
File "<pip-setuptools-caller>", line 34, in <module>
File "/tmp/pip-install-6l9ppgj8/dlib_a9ff28b611c041e7822ffaa612e7c30a/setup.py", line 222, in <module>
setup(
File "/usr/lib/python3/dist-packages/setuptools/__init__.py", line 144, in setup
return distutils.core.setup(**attrs)
File "/usr/lib/python3.8/distutils/core.py", line 148, in setup
dist.run_commands()
File "/usr/lib/python3.8/distutils/dist.py", line 966, in run_commands
self.run_command(cmd)
File "/usr/lib/python3.8/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/usr/lib/python3/dist-packages/setuptools/command/install.py", line 61, in run
return orig.install.run(self)
File "/usr/lib/python3.8/distutils/command/install.py", line 589, in run
self.run_command('build')
File "/usr/lib/python3.8/distutils/cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "/usr/lib/python3.8/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/usr/lib/python3.8/distutils/command/build.py", line 135, in run
self.run_command(cmd_name)
File "/usr/lib/python3.8/distutils/cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "/usr/lib/python3.8/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/tmp/pip-install-6l9ppgj8/dlib_a9ff28b611c041e7822ffaa612e7c30a/setup.py", line 134, in run
self.build_extension(ext)
File "/tmp/pip-install-6l9ppgj8/dlib_a9ff28b611c041e7822ffaa612e7c30a/setup.py", line 171, in build_extension
subprocess.check_call(cmake_setup, cwd=build_folder)
File "/usr/lib/python3.8/subprocess.py", line 364, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['cmake', '/tmp/pip-install-6l9ppgj8/dlib_a9ff28b611c041e7822ffaa612e7c30a/tools/python', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=/tmp/pip-install-6l9ppgj8/dlib_a9ff28b611c041e7822ffaa612e7c30a/build/lib.linux-x86_64-3.8', '-DPYTHON_EXECUTABLE=/usr/bin/python3', '-DCMAKE_BUILD_TYPE=Release']' 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.```
in advance thanks for your help
from
zain

ERROR: Could not build wheels for onnx, pycocotools, which is required to install pyproject.toml-based projects

was trying to install yolox
pip install -r requirements.txt and got this
Using legacy 'setup.py install' for onnx-simplifier, since package 'wheel' is not installed.
Building wheels for collected packages: onnx, pycocotools
Building wheel for onnx (pyproject.toml) ... error
error: subprocess-exited-with-error
× Building wheel for onnx (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [82 lines of output]
C:\Users\ASUS\AppData\Local\Temp\pip-build-env-du9u4xrx\overlay\Lib\site-packages\setuptools\dist.py:757: UserWarning: Usage of dash-separated 'license-file' will not be supported in future versions. Please use the underscore name 'license_file' instead
warnings.warn(
running bdist_wheel
running build
running build_py
running create_version
running cmake_build
-- Building for: NMake Makefiles
CMake Error at CMakeLists.txt:17 (project):
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/ASUS/AppData/Local/Temp/pip-install-9m548hbh/onnx_ad97fc2a0af84a5fa92a29cfbc51c296/.setuptools-cmake-build/CMakeFiles/CMakeOutput.log".
Traceback (most recent call last):
File "c:\users\asus\appdata\local\programs\python\python39\lib\site-packages\pip\_vendor\pep517\in_process\_in_process.py", line 363, in <module>
main()
File "c:\users\asus\appdata\local\programs\python\python39\lib\site-packages\pip\_vendor\pep517\in_process\_in_process.py", line 345, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "c:\users\asus\appdata\local\programs\python\python39\lib\site-packages\pip\_vendor\pep517\in_process\_in_process.py", line 261, in build_wheel
return _build_backend().build_wheel(wheel_directory, config_settings,
File "C:\Users\ASUS\AppData\Local\Temp\pip-build-env-du9u4xrx\overlay\Lib\site-packages\setuptools\build_meta.py", line 244, in build_wheel
return self._build_with_temp_dir(['bdist_wheel'], '.whl',
File "C:\Users\ASUS\AppData\Local\Temp\pip-build-env-du9u4xrx\overlay\Lib\site-packages\setuptools\build_meta.py", line 229, in _build_with_temp_dir
self.run_setup()
File "C:\Users\ASUS\AppData\Local\Temp\pip-build-env-du9u4xrx\overlay\Lib\site-packages\setuptools\build_meta.py", line 281, in run_setup
super(_BuildMetaLegacyBackend,
File "C:\Users\ASUS\AppData\Local\Temp\pip-build-env-du9u4xrx\overlay\Lib\site-packages\setuptools\build_meta.py", line 174, in run_setup
exec(compile(code, __file__, 'exec'), locals())
File "setup.py", line 321, in <module>
setuptools.setup(
File "C:\Users\ASUS\AppData\Local\Temp\pip-build-env-du9u4xrx\overlay\Lib\site-packages\setuptools\__init__.py", line 87, in setup
return distutils.core.setup(**attrs)
File "C:\Users\ASUS\AppData\Local\Temp\pip-build-env-du9u4xrx\overlay\Lib\site-packages\setuptools\_distutils\core.py", line 148, in setup
return run_commands(dist)
File "C:\Users\ASUS\AppData\Local\Temp\pip-build-env-du9u4xrx\overlay\Lib\site-packages\setuptools\_distutils\core.py", line 163, in run_commands
dist.run_commands()
File "C:\Users\ASUS\AppData\Local\Temp\pip-build-env-du9u4xrx\overlay\Lib\site-packages\setuptools\_distutils\dist.py", line 967, in run_commands
self.run_command(cmd)
File "C:\Users\ASUS\AppData\Local\Temp\pip-build-env-du9u4xrx\overlay\Lib\site-packages\setuptools\dist.py", line 1214, in run_command
super().run_command(command)
File "C:\Users\ASUS\AppData\Local\Temp\pip-build-env-du9u4xrx\overlay\Lib\site-packages\setuptools\_distutils\dist.py", line 986, in run_command
cmd_obj.run()
File "C:\Users\ASUS\AppData\Local\Temp\pip-build-env-du9u4xrx\overlay\Lib\site-packages\wheel\bdist_wheel.py", line 299, in run
self.run_command('build')
File "C:\Users\ASUS\AppData\Local\Temp\pip-build-env-du9u4xrx\overlay\Lib\site-packages\setuptools\_distutils\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "C:\Users\ASUS\AppData\Local\Temp\pip-build-env-du9u4xrx\overlay\Lib\site-packages\setuptools\dist.py", line 1214, in run_command
super().run_command(command)
File "C:\Users\ASUS\AppData\Local\Temp\pip-build-env-du9u4xrx\overlay\Lib\site-packages\setuptools\_distutils\dist.py", line 986, in run_command
cmd_obj.run()
File "C:\Users\ASUS\AppData\Local\Temp\pip-build-env-du9u4xrx\overlay\Lib\site-packages\setuptools\_distutils\command\build.py", line 135, in run
self.run_command(cmd_name)
File "C:\Users\ASUS\AppData\Local\Temp\pip-build-env-du9u4xrx\overlay\Lib\site-packages\setuptools\_distutils\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "C:\Users\ASUS\AppData\Local\Temp\pip-build-env-du9u4xrx\overlay\Lib\site-packages\setuptools\dist.py", line 1214, in run_command
super().run_command(command)
File "C:\Users\ASUS\AppData\Local\Temp\pip-build-env-du9u4xrx\overlay\Lib\site-packages\setuptools\_distutils\dist.py", line 986, in run_command
cmd_obj.run()
File "setup.py", line 217, in run
self.run_command('cmake_build')
File "C:\Users\ASUS\AppData\Local\Temp\pip-build-env-du9u4xrx\overlay\Lib\site-packages\setuptools\_distutils\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "C:\Users\ASUS\AppData\Local\Temp\pip-build-env-du9u4xrx\overlay\Lib\site-packages\setuptools\dist.py", line 1214, in run_command
super().run_command(command)
File "C:\Users\ASUS\AppData\Local\Temp\pip-build-env-du9u4xrx\overlay\Lib\site-packages\setuptools\_distutils\dist.py", line 986, in run_command
cmd_obj.run()
File "setup.py", line 203, in run
subprocess.check_call(cmake_args)
File "c:\users\asus\appdata\local\programs\python\python39\lib\subprocess.py", line 373, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['C:\\Users\\ASUS\\anaconda3\\envs\\myenv\\Library\\bin\\cmake.exe', '-DPYTHON_INCLUDE_DIR=c:\\users\\asus\\appdata\\local\\programs\\python\\python39\\include', '-DPYTHON_EXECUTABLE=c:\\users\\asus\\appdata\\local\\programs\\python\\python39\\python.exe', '-DBUILD_ONNX_PYTHON=ON', '-DCMAKE_EXPORT_COMPILE_COMMANDS=ON', '-DONNX_NAMESPACE=onnx', '-DPY_EXT_SUFFIX=.cp39-win_amd64.pyd', '-DCMAKE_BUILD_TYPE=Release', '-DPY_VERSION=3.9', '-DONNX_USE_MSVC_STATIC_RUNTIME=ON', '-A', 'x64', '-T', 'host=x64', '-DONNX_ML=1', 'C:\\Users\\ASUS\\AppData\\Local\\Temp\\pip-install-9m548hbh\\onnx_ad97fc2a0af84a5fa92a29cfbc51c296']' 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 onnx
Building wheel for pycocotools (pyproject.toml) ... error
error: subprocess-exited-with-error
× Building wheel for pycocotools (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [14 lines of output]
running bdist_wheel
running build
running build_py
creating build
creating build\lib.win-amd64-3.9
creating build\lib.win-amd64-3.9\pycocotools
copying pycocotools\coco.py -> build\lib.win-amd64-3.9\pycocotools
copying pycocotools\cocoeval.py -> build\lib.win-amd64-3.9\pycocotools
copying pycocotools\mask.py -> build\lib.win-amd64-3.9\pycocotools
copying pycocotools_init_.py -> build\lib.win-amd64-3.9\pycocotools
running build_ext
skipping 'pycocotools_mask.c' Cython extension (up-to-date)
building 'pycocotools._mask' extension
error: Microsoft Visual C++ 14.0 or greater is required. Get it with "Microsoft C++ Build Tools": https://visualstudio.microsoft.com/visual-cpp-build-tools/
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for pycocotools
Failed to build onnx pycocotools
ERROR: Could not build wheels for onnx, pycocotools, which is required to install pyproject.toml-based projects
(myenv) C:\Users\ASUS\Desktop\YOLOX-main>
since package 'wheel' is not installed
install wheel:
pip3 install wheel
If you are using Conda environment you can run this commmand
conda install -c conda-forge pycocotools

Cannot install face_recognition using pip install face_recognition on Win10

I get the error
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
╰─> [58 lines of output]
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
Building extension for Python 3.10.4 (tags/v3.10.4:9d38120, Mar 23 2022, 23:13:41) [MSC v.1929 64 bit (AMD64)]
Invoking CMake setup: 'cmake C:\Users\amade\AppData\Local\Temp\pip-install-_k5e982w\dlib_237006073dfd4b13993bf60b7ecb3629\tools\python -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=C:\Users\amade\AppData\Local\Temp\pip-install-_k5e982w\dlib_237006073dfd4b13993bf60b7ecb3629\build\lib.win-amd64-3.10 -DPYTHON_EXECUTABLE=C:\Users\amade\AppData\Local\Microsoft\WindowsApps\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\python.exe -DCMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE=C:\Users\amade\AppData\Local\Temp\pip-install-_k5e982w\dlib_237006073dfd4b13993bf60b7ecb3629\build\lib.win-amd64-3.10 -A x64'
-- Building for: Visual Studio 17 2022
-- Selecting Windows SDK version to target Windows 10.0.19044.
-- The C compiler identification is unknown
-- The CXX compiler identification is unknown
CMake Error at CMakeLists.txt:14 (project):
No CMAKE_C_COMPILER could be found.
CMake Error at CMakeLists.txt:14 (project):
No CMAKE_CXX_COMPILER could be found.
-- Configuring incomplete, errors occurred!
See also "C:/Users/amade/AppData/Local/Temp/pip-install-_k5e982w/dlib_237006073dfd4b13993bf60b7ecb3629/build/temp.win-amd64-3.10/Release/CMakeFiles/CMakeOutput.log".
See also "C:/Users/amade/AppData/Local/Temp/pip-install-_k5e982w/dlib_237006073dfd4b13993bf60b7ecb3629/build/temp.win-amd64-3.10/Release/CMakeFiles/CMakeError.log".
Traceback (most recent call last):
File "<string>", line 2, in <module>
File "<pip-setuptools-caller>", line 34, in <module>
File "C:\Users\amade\AppData\Local\Temp\pip-install-_k5e982w\dlib_237006073dfd4b13993bf60b7ecb3629\setup.py", line 222, in <module>
setup(
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1264.0_x64__qbz5n2kfra8p0\lib\site-packages\setuptools\__init__.py", line 153, in setup
return distutils.core.setup(**attrs)
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1264.0_x64__qbz5n2kfra8p0\lib\distutils\core.py", line 148, in setup
dist.run_commands()
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1264.0_x64__qbz5n2kfra8p0\lib\distutils\dist.py", line 966, in run_commands
self.run_command(cmd)
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1264.0_x64__qbz5n2kfra8p0\lib\distutils\dist.py", line 985, in run_command
cmd_obj.run()
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1264.0_x64__qbz5n2kfra8p0\lib\site-packages\setuptools\command\install.py", line 61, in run
return orig.install.run(self)
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1264.0_x64__qbz5n2kfra8p0\lib\distutils\command\install.py", line 568, in run
self.run_command('build')
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1264.0_x64__qbz5n2kfra8p0\lib\distutils\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1264.0_x64__qbz5n2kfra8p0\lib\distutils\dist.py", line 985, in run_command
cmd_obj.run()
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1264.0_x64__qbz5n2kfra8p0\lib\distutils\command\build.py", line 135, in run
self.run_command(cmd_name)
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1264.0_x64__qbz5n2kfra8p0\lib\distutils\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1264.0_x64__qbz5n2kfra8p0\lib\distutils\dist.py", line 985, in run_command
cmd_obj.run()
File "C:\Users\amade\AppData\Local\Temp\pip-install-_k5e982w\dlib_237006073dfd4b13993bf60b7ecb3629\setup.py", line 134, in run
self.build_extension(ext)
File "C:\Users\amade\AppData\Local\Temp\pip-install-_k5e982w\dlib_237006073dfd4b13993bf60b7ecb3629\setup.py", line 171, in build_extension
subprocess.check_call(cmake_setup, cwd=build_folder)
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1264.0_x64__qbz5n2kfra8p0\lib\subprocess.py", line 369, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['cmake', 'C:\\Users\\amade\\AppData\\Local\\Temp\\pip-install-_k5e982w\\dlib_237006073dfd4b13993bf60b7ecb3629\\tools\\python', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=C:\\Users\\amade\\AppData\\Local\\Temp\\pip-install-_k5e982w\\dlib_237006073dfd4b13993bf60b7ecb3629\\build\\lib.win-amd64-3.10', '-DPYTHON_EXECUTABLE=C:\\Users\\amade\\AppData\\Local\\Microsoft\\WindowsApps\\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\\python.exe', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE=C:\\Users\\amade\\AppData\\Local\\Temp\\pip-install-_k5e982w\\dlib_237006073dfd4b13993bf60b7ecb3629\\build\\lib.win-amd64-3.10', '-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.
Follow the steps below to install face_recognition python package on Windows 10.
The instruction has been tested on Windows 10 64bit, python 3.9.
Step 1
Download CMake installation package for your OS from official site
Step 2
Install downloaded CMake installation package. Please make sure that Add CMake to system PATH option has been selected during the installation.
Step 3
Reboot your OS (restart computer)
Step 4
Run pip install dlib
It tooks several minutes so be prepared to wait
Step 5
If it completes without any errors, you're all set. Run pip install face_recognition to install face_recognition.
Result
Fixed it. I had to modify my Visual Studio install from Start menu programs, and include latest MSVC and include Windows 10 SDK under Individual Components

How to install ciso8601 with pip3? [duplicate]

This question already has answers here:
Error "Microsoft Visual C++ 14.0 is required (Unable to find vcvarsall.bat)"
(36 answers)
Error while installing lxml through pip: Microsoft Visual C++ 14.0 is required
(8 answers)
Pip error even Microsoft Visual C++ 14.0 is installed
(4 answers)
How to solve "error: Microsoft Visual C++ 14.0 or greater is required" when installing Python packages?
(9 answers)
Closed last year.
I hit an issue when I want to install ciso8601 with Windows Command Prompt, usig pip3.
I have Python 3.8.10 vesion installed, when I write pip3 install ciso8601 in the command prompt, I have this error message :
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for ciso8601
Failed to build ciso8601
ERROR: Could not build wheels for ciso8601, which is required to install pyproject.toml-based projects
I initially encountered this error when I wanted to install ftx package.
Installing the wheelpackage didn't help.
The following code is the entire message I get when I install ciso8601 :
C:\Users\Hugo>pip3 install ciso8601
Collecting ciso8601
Using cached ciso8601-2.2.0.tar.gz (18 kB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... done
Building wheels for collected packages: ciso8601
Building wheel for ciso8601 (pyproject.toml) ... error
error: subprocess-exited-with-error
× Building wheel for ciso8601 (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [66 lines of output]
running bdist_wheel
running build
running build_py
package init file 'ciso8601\__init__.py' not found (or not a regular file)
running build_ext
building 'ciso8601' extension
Traceback (most recent call last):
File "c:\users\hugo\appdata\local\programs\python\python38\lib\site-packages\pip\_vendor\pep517\in_process\_in_process.py", line 363, in <module>
main()
File "c:\users\hugo\appdata\local\programs\python\python38\lib\site-packages\pip\_vendor\pep517\in_process\_in_process.py", line 345, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "c:\users\hugo\appdata\local\programs\python\python38\lib\site-packages\pip\_vendor\pep517\in_process\_in_process.py", line 261, in build_wheel
return _build_backend().build_wheel(wheel_directory, config_settings,
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\build_meta.py", line 229, in build_wheel
return self._build_with_temp_dir(['bdist_wheel'], '.whl',
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\build_meta.py", line 214, in _build_with_temp_dir
self.run_setup()
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\build_meta.py", line 266, in run_setup
super(_BuildMetaLegacyBackend,
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\build_meta.py", line 157, in run_setup
exec(compile(code, __file__, 'exec'), locals())
File "setup.py", line 37, in <module>
setup(
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\__init__.py", line 155, in setup
return distutils.core.setup(**attrs)
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\_distutils\core.py", line 148, in setup
return run_commands(dist)
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\_distutils\core.py", line 163, in run_commands
dist.run_commands()
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\_distutils\dist.py", line 967, in run_commands
self.run_command(cmd)
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\_distutils\dist.py", line 986, in run_command
cmd_obj.run()
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\wheel\bdist_wheel.py", line 299, in run
self.run_command('build')
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\_distutils\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\_distutils\dist.py", line 986, in run_command
cmd_obj.run()
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\_distutils\command\build.py", line 135, in run
self.run_command(cmd_name)
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\_distutils\cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\_distutils\dist.py", line 986, in run_command
cmd_obj.run()
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\command\build_ext.py", line 79, in run
_build_ext.run(self)
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\_distutils\command\build_ext.py", line 339, in run
self.build_extensions()
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\_distutils\command\build_ext.py", line 448, in build_extensions
self._build_extensions_serial()
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\_distutils\command\build_ext.py", line 473, in _build_extensions_serial
self.build_extension(ext)
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\command\build_ext.py", line 202, in build_extension
_build_ext.build_extension(self, ext)
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\_distutils\command\build_ext.py", line 528, in build_extension
objects = self.compiler.compile(sources,
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\_distutils\_msvccompiler.py", line 327, in compile
self.initialize()
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\_distutils\_msvccompiler.py", line 224, in initialize
vc_env = _get_vc_env(plat_spec)
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\msvc.py", line 316, in msvc14_get_vc_env
return _msvc14_get_vc_env(plat_spec)
File "C:\Users\Hugo\AppData\Local\Temp\pip-build-env-d8m37jb0\overlay\Lib\site-packages\setuptools\msvc.py", line 270, in _msvc14_get_vc_env
raise distutils.errors.DistutilsPlatformError(
setuptools._distutils.errors.DistutilsPlatformError: Microsoft Visual C++ 14.0 or greater is required. Get it with "Microsoft C++ Build Tools": https://visualstudio.microsoft.com/visual-cpp-build-tools/
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for ciso8601
Failed to build ciso8601
ERROR: Could not build wheels for ciso8601, which is required to install pyproject.toml-based projects

Categories