0

I am trying to install the Isotree package from pip install, when I receive the error below. I am using Python 3.7, working on a Windows 8 with installed C++ build tools using Visual studio build tools 2019 (version 16.7.5). I have also included Windows 10 SDK (10.0.18362.0) along with other add-ons.

I have tried all possible solutions I found to similar problems on this website and via other google searches, but I can't seem to get it working. Since I am working on a work laptop, I cannot go around and download from another party.

Can somebody help me how to resolve this problem? I tried setting an environment variable INCLUDE, pointing to the folder [C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\ucrt] this helped but another error occurred, "cannot open include: basetsd.h" and then trying to solve that, the original error (io.h) came back.

  Building wheel for isotree (PEP 517) ... error
  ERROR: Command errored out with exit status 1:
   command: 'c:\users\a481838\appdata\local\programs\python\python37\python.exe'
 'c:\users\a481838\appdata\local\programs\python\python37\lib\site-packages\pip\
_vendor\pep517\_in_process.py' build_wheel 'C:\Users\A481838\AppData\Local\Temp\
tmpslnm97j9'
       cwd: C:\Users\A481838\AppData\Local\Temp\pip-install-uxt3l0k4\isotree
  Complete output (28 lines):
  running bdist_wheel
  running build
  running build_py
  creating build
  creating build\lib.win-amd64-3.7
  creating build\lib.win-amd64-3.7\isotree
  copying isotree\__init__.py -> build\lib.win-amd64-3.7\isotree
  running build_ext
  cythoning isotree/cpp_interface.pyx to isotree\cpp_interface.cpp
  building 'isotree._cpp_interface' extension
  creating build\temp.win-amd64-3.7
  creating build\temp.win-amd64-3.7\Release
  creating build\temp.win-amd64-3.7\Release\isotree
  creating build\temp.win-amd64-3.7\Release\src
  C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\1
4.27.29110\bin\HostX86\x64\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD -D_USE_MER
SENNE_TWISTER -D_ENABLE_CEREAL -IC:\Users\A481838\AppData\Local\Temp\pip-build-e
nv-7aj7e0rh\overlay\Lib\site-packages\numpy\core\include -I. -I./src -IC:\Users\
A481838\AppData\Local\Temp\pip-build-env-7aj7e0rh\overlay\include -Ic:\users\a48
1838\appdata\local\programs\python\python37\include -Ic:\users\a481838\appdata\l
ocal\programs\python\python37\include "-IC:\Program Files (x86)\Microsoft Visual
 Studio\2019\BuildTools\VC\Tools\MSVC\14.27.29110\include" "-IC:\Program Files (
x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.27.29110\include"
"-IC:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\ucrt" /EHsc /Tpis
otree\cpp_interface.cpp /Fobuild\temp.win-amd64-3.7\Release\isotree\cpp_interfac
e.obj /openmp /O2 /std:c++14
  cpp_interface.cpp
  c:\users\a481838\appdata\local\programs\python\python37\include\pyconfig.h(59)
: fatal error C1083: Cannot open include file: 'io.h': No such file or directory

  c:\users\a481838\appdata\local\programs\python\python37\lib\distutils\extensio
n.py:131: UserWarning: Unknown Extension options: 'install_requires'
    warnings.warn(msg)
  C:\Users\A481838\AppData\Local\Temp\pip-build-env-7aj7e0rh\overlay\Lib\site-pa
ckages\Cython\Compiler\Main.py:369: FutureWarning: Cython directive 'language_le
vel' not set, using 2 for now (Py2). This will change in a later release! File:
C:\Users\A481838\AppData\Local\Temp\pip-install-uxt3l0k4\isotree\isotree\cpp_int
erface.pyx
    tree = Parsing.p_module(s, pxd, full_module_name)
  warning: isotree\cpp_interface.pyx:384:44: Not all members given for struct 'I
soForest'
  warning: isotree\cpp_interface.pyx:384:44: Not all members given for struct 'I
soForest'
  warning: isotree\cpp_interface.pyx:387:47: Not all members given for struct 'E
xtIsoForest'
  warning: isotree\cpp_interface.pyx:387:47: Not all members given for struct 'E
xtIsoForest'
  warning: isotree\cpp_interface.pyx:391:34: Not all members given for struct 'I
mputer'
  warning: isotree\cpp_interface.pyx:391:34: Not all members given for struct 'I
mputer'
  error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\BuildT
ools\\VC\\Tools\\MSVC\\14.27.29110\\bin\\HostX86\\x64\\cl.exe' failed with exit
status 2
  ----------------------------------------
  ERROR: Failed building wheel for isotree
Failed to build isotree
ERROR: Could not build wheels for isotree which use PEP 517 and cannot be instal
led directly``` 

  • https://stackoverflow.com/questions/53204916/what-is-the-meaning-of-failed-building-wheel-for-x-in-pip-install – Shijith Oct 15 '20 at 20:00
  • Thank you for your reply. I checked out the link you send, I ran the ```pip install wheel, and that works sucessfully. Unfortunately, still not able to install isotree after that, giving rise to the same error message. – Yasmine Keehnen Oct 16 '20 at 07:06

1 Answers1

0

Type the following.

pip install pipwin
pipwin install pycuda
BeeFriedman
  • 1,800
  • 1
  • 11
  • 29
  • Thanks for your reply. I ran the code you provided, but now I have a new error. Everything is the same as mentioned above, but in stead of "cannot open include file: io.h", I get: "fatal error C1083: Cannot open include file: 'basetsd.h': No such file or directory". What can I do to solve this error? – Yasmine Keehnen Oct 16 '20 at 07:09
  • https://stackoverflow.com/questions/23691564/ look in to the second answer hope it helps you. – BeeFriedman Oct 16 '20 at 07:37
  • thanks again for your quick response. I had already tried that solution but it didn't help. Do you have any other thoughts? – Yasmine Keehnen Oct 16 '20 at 09:58