Installing the Python version of Xgboost under the window platform

Source: Internet
Author: User

Original: http://blog.csdn.net/pengyulong/article/details/50515916

The original revised two places to install the success, the 3rd step can not be used, the 2nd step to regenerate all the line.

4th step, after "Xgboost_wrapper.dll", copy the file to/python-package/xgboost/and continue with the next steps.

Special Note If your Python is 32-bit, the second step is not to choose x64, but to choose Win32. The corresponding file is not under x64. Must be able to run.

The full name of Xgboost is extreme Gradient boosting. It is a C + + implementation of gradient boosting machine. For data classification, it is fast and accurate, and it shines on many data mining competitions (such as Kaggle). Here's how to install the Python version of Xgboost under the window platform.

First, introduce my software configuration environment and provide a reference for the Python version that you want to install Xgboost: My notebook's system is WIN10 (this doesn't matter, win7,win8.1,win10 can), Python uses Python 3.5 (python 3 should all be possible), Visual Studio 2015 (This is for Xgboost compilation, VS2010 above should be possible). Once these tools are ready, the installation begins below:

      1. Download xgboost: Download link https://github.com/dmlc/xgboost/You can see this is placed on the githup, if you know Githup, directly with Gitclone on it, I am not familiar with Gitup, so click on the " Download zip "Download, download, unzip into a folder just fine.
      2. C + + compiled Xgboost:, open the ".../xgboost-master/windows/" folder, open "Xgboost.sln" under the folder in Visual Studio, and then select Set "solution Configuration" to "Release", set " The solution platform, "x64", generates a solution (see how to set it up), which is considered successful without an error.
      3. C + + compiled wrapper: (This step is very critical, I just started to forget to compile this, the following will not go on.) ), open the ".../xgboost-master/wrapper/" folder and use the same method as the 2nd step to open "xgboost_wrapper.cpp" and compile.
      4. Check the ".../xgboost-master/windows/x64/release/" folder for "Xgboost_wrapper.dll" if it contains, it means that the first two steps are successful, the following steps into the final step of the installation process.
      5. Open ".../xgboost-master/python-package/" and open the command-line window here (you can also use the cmd command to enter the directory) and enter "python setup.py install".
      6. After the above steps are completed, enter "Import Xgboost" in the Pyhon environment to see if there is an error, if there is no error, it indicates the installation is successful.

Installing the Python version of Xgboost under the window platform

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.