Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

已解决-Windows上安装pyrfr #99

Closed
2catycm opened this issue Sep 15, 2024 · 0 comments
Closed

已解决-Windows上安装pyrfr #99

2catycm opened this issue Sep 15, 2024 · 0 comments

Comments

@2catycm
Copy link

2catycm commented Sep 15, 2024

这里指示了如何配置vc的环境 https://open-box.readthedocs.io/zh-cn/latest/installation/install_microsoft_vc.html
然而如果只装那两个是不work的,会遇到

× python setup.py bdist_wheel did not run successfully.
  │ exit code: 1
  ╰─> [8 lines of output]
      [<setuptools.extension.Extension('pyrfr._regression') at 0x19ce8dcdd50>, <setuptools.extension.Extension('pyrfr._util') at 0x19ce8e96950>]
      Deprecated command line option: -modern. Ignored, this option is now always on.
      Deprecated command line option: -py3. Ignored, this option is no longer supported.
      .\include\rfr\nodes\k_ary_node.hpp(253) : Warning 401: Nothing known about base class 'k_ary_node_minimal< 2,rfr::splits::binary_split_one_feature_rss_loss< double,double,unsigned int,std::default_random_engine,128 >,double,double,unsigned int,std::default_random_engine >'. Ignored.
      .\include\rfr\nodes\k_ary_node.hpp(253) : Warning 401: Maybe you forgot to instantiate 'k_ary_node_minimal< 2,rfr::splits::binary_split_one_feature_rss_loss< double,double,unsigned int,std::default_random_engine,128 >,double,double,unsigned int,std::default_random_engine >' using %template.
      regression_wrap.cpp
      D:\DevEnvironment\anaconda3\envs\agn\include\pyconfig.h(59): fatal error C1083: 无法打开包括文件: io.h: No such file or directory
      error: command 'D:\\DevEnvironment\\VisualStudio\\VC\\Tools\\MSVC\\14.41.34120\\bin\\HostX86\\x64\\cl.exe' failed with exit code 2
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for pyrfr
  Running setup.py clean for pyrfr
Failed to build pyrfr
ERROR: Could not build wheels for pyrfr, which is required to install pyproject.toml-based projects

根据Microsoft的答疑 https://learn.microsoft.com/en-us/answers/questions/1386273/io-h-not-found
解法很简单,VC Installer中多勾选一个 Windows 11/10 SDK
亲测确实解决了

@2catycm 2catycm closed this as completed Sep 15, 2024
@2catycm 2catycm changed the title Windows上安装pyrfr的教程需要更新 已解决-Windows上安装pyrfr的教程需要更新 Sep 15, 2024
@2catycm 2catycm changed the title 已解决-Windows上安装pyrfr的教程需要更新 已解决-Windows上安装pyrfr Sep 15, 2024
@jhj0411jhj jhj0411jhj reopened this Sep 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants