报错如图
ModuleNotFoundError: No module named 'distutils.core'
had the same problem today. I believe the issue is the instructions you listed are out of date for Python installs, as they are now enabled with pip install.
Delete the xgboost directory that your above install attempt created, and then execute:
pip install xgboost
It should all work with one command. See also the Python Specific XGBoost Install Instructions.
推荐使用 virtualenv 建立虚拟 python 环境,以免和系统的 python 产生冲突,进而影响系统其他应用。
或使用 Miniconda 的 python 发行版( https://conda.io/miniconda.html ),用这个做科学计算更方便。