実現したいこと
- pip install を実行した際に表示されるエラーについて、その原因を究明したい
前提
現在pythonを用いてベイズ最適化を行っています。
GPyOptをインストールしようとしたのですが、エラーメッセージが表示されるようになりました。
7月には問題なく実行できていたので、おそらく8月に入ってからエラーが表示されるようになったのではないかと思います。
そのエラーの原因について、もしご存じの方がいらっしゃったら教えていただきたいです。
発生している問題・エラーメッセージ
以下にエラーメッセージを記載しています。
非常に長いエラーメッセージなので、一部を省略して記載しています。
error: subprocess-exited-with-error python setup.py bdist_wheel did not run successfully. exit code: 1 [415 lines of output] C:\Users\yoslab2\AppData\Roaming\pyaedt_env_ide\v232\lib\site-packages\setuptools\dist.py:771: UserWarning: Usage of dash-separated 'upload-dir' will not be supported in future versions. Please use the underscore name 'upload_dir' instead warnings.warn( ~~ 省略 ~~ copying GPy\plotting\plotly_dep\__init__.py -> build\lib.win-amd64-cpython-310\GPy\plotting\plotly_dep running egg_info writing GPy.egg-info\PKG-INFO writing dependency_links to GPy.egg-info\dependency_links.txt writing requirements to GPy.egg-info\requires.txt writing top-level names to GPy.egg-info\top_level.txt reading manifest file 'GPy.egg-info\SOURCES.txt' reading manifest template 'MANIFEST.in' warning: no files found matching 'README.rst' adding license file 'LICENSE.txt' adding license file 'AUTHORS.txt' writing manifest file 'GPy.egg-info\SOURCES.txt' C:\Users\yoslab2\AppData\Roaming\pyaedt_env_ide\v232\lib\site-packages\setuptools\command\build_py.py:202: SetuptoolsDeprecationWarning: Installing 'GPy.kern.src' as data is deprecated, please list it in `packages`. !! ############################ # Package would be ignored # ############################ Python recognizes 'GPy.kern.src' as an importable package, but it is not listed in the `packages` configuration of setuptools. 'GPy.kern.src' has been automatically added to the distribution only because it may contain data files, but this behavior is likely to change in future versions of setuptools (and therefore is considered deprecated). Please make sure that 'GPy.kern.src' is included as a package by using the `packages` configuration field or the proper discovery methods (for example by using `find_namespace_packages(...)`/`find_namespace:` instead of `find_packages(...)`/`find:`). You can read more about "package discovery" and "data files" on setuptools documentation page. !! ~~ 省略 ~~ running build_ext building 'GPy.kern.src.stationary_cython' 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 GPy ERROR: Could not build wheels for GPy, which is required to install pyproject.toml-based projects
エラーメッセージの後半部分に、
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/
とあるので、おそらく Microsoft Visual C++ 14.0以上のバージョンをインストールすれば解決するかもしれません。
とりあえずそちらを実行しようとは思うので、エラーメッセージ自体は解決する可能性もあるのですが、急にこのようなエラーメッセージが表示されるようになった原因が分かりません。
これは Microsoft Visual C++ 14.0以上のバージョンをインストールしないと解決しないエラーなのでしょうか?
そちらをインストールする以外にも解決方法というのはあるのでしょうか?
もしこのエラーメッセージが表示されるようになった原因が分かる方がいらっしゃいましたら、教えていただきたいです。
該当のソースコード
python
1pip install GPyOpt
試したこと
初めは pip の問題かと思いアップデートなども試してみましたが、状況は変化しませんでした。
エラーメッセージにも
note: This error originates from a subprocess, and is likely not a problem with pip.
とあるように、pip の問題ではないようです。
また、GPyOpt 以外にも、GPy や matplotlib==3.1.3 などを同様に pip install を用いてインストールしようとしたのですが、同様のエラーメッセージが表示されました。
補足情報(FW/ツールのバージョンなど)
- python:3.10.9
- Jupyter Notebook





回答1件
あなたの回答
tips
プレビュー