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

[docs] Simplify the python installation instruction #3378

Merged
merged 2 commits into from
Sep 11, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions docs/Python-Intro.rst
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,13 @@ This document gives a basic walkthrough of LightGBM Python-package.
Install
-------

Install Python-package dependencies,
``setuptools``, ``wheel``, ``numpy`` and ``scipy`` are required, ``scikit-learn`` is required for sklearn interface and recommended:
You can install LightGBM via pip

::

pip install setuptools wheel numpy scipy scikit-learn -U
pip install lightgbm

Refer to `Python-package`_ folder for the installation guide.
Refer to `Python-package`_ folder for the detailed installation guide.

To verify your installation, try to ``import lightgbm`` in Python:

Expand Down
12 changes: 7 additions & 5 deletions python-package/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,13 @@ Preparation
Install from `PyPI <https://pypi.org/project/lightgbm>`_ Using ``pip``
''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''

.. code:: sh

pip install lightgbm


You may need to install `wheel <https://pythonwheels.com>`_ via ``pip install wheel`` first.

For **Windows** users, `VC runtime <https://support.microsoft.com/en-us/help/2977003/the-latest-supported-visual-c-downloads>`_ is needed if **Visual Studio** (2015 or newer) is not installed.

For **Linux** users, **glibc** >= 2.14 is required.
Expand All @@ -28,11 +35,6 @@ For **macOS** (we provide wheels for 3 newest macOS versions) users:

- For version smaller than 2.1.2, **gcc-7** with **OpenMP** is required.

Install `wheel <https://pythonwheels.com>`_ via ``pip install wheel`` first. After that download the wheel file and install from it:

.. code:: sh

pip install lightgbm

Build from Sources
******************
Expand Down