I have miniconda with python 3.6.1, conda 4.3.22 & Win 10 64 bit. But the solution that I’ve provided should work even for those who don’t use conda. Skip to the end section to directly get to the solution.
I’ll make this long story short. I tried to install XGBoost on my windows machine, this was a big deal because It didn’t work for me. First of all I tried conda’s installation command :
conda install xgboost
Which didn’t work well for me because there is no installation support for xgboost for win 64 channel at the time.
Insertion : (Anaconda’s conda install xgboost supports currently linux and mac at the time, unless you try “py-xgboost” which I realized at the time of writing this article. I however haven’t tried installing “py-boost”).
I used pip install xgboost, for which it said something that I couldn’t understand.
Here is what it said :
No files/directories in C:\Users\Username\AppData\Local\Temp\pip-build-u83gbuco\xgboost\pip-egg-info (from PKG-INFO)
Well, I googled the same term for which I got a whole bunch of github closed solutions, that unfortunately didn’t fix my problem here:
I followed up with the solutions from github leading to stack overflow where they suggest to compile the xgboost package from the c++ compiler which still didn’t work for me.
If you want, here is the instructions I found;
Finally here comes the solution that worked for me:
How to Install in the simplest way:
- Download the Appropriate .whl file for your environment from here .
- Open your command prompt and cd into the downloaded folder.
- Now simply issue the pip install command to the downloaded .whl file like so:
pip install xgboost-0.6-cp36-cp36m-win_amd64.whl
- Just to prove it works, I’ve attached a screenshot of imported xgboost:
Very Important :
Make sure you download the correct .whl for you version, otherwise this method won’t work. For your reference, I downloaded “xgboost-0.6-cp36-cp36m-win_amd64.whl” file.