You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: doc/gpu/index.rst
+5-4
Original file line number
Diff line number
Diff line change
@@ -22,21 +22,22 @@ Supported parameters
22
22
GPU accelerated prediction is enabled by default for the above mentioned ``tree_method`` parameters but can be switched to CPU prediction by setting ``predictor`` to ``cpu_predictor``. This could be useful if you want to conserve GPU memory. Likewise when using CPU algorithms, GPU accelerated prediction can be enabled by setting ``predictor`` to ``gpu_predictor``.
23
23
24
24
The device ordinal (which GPU to use if you have many of them) can be selected using the
25
-
``gpu_id`` parameter, which defaults to 0 (the first device reported by CUDA runtime).
25
+
``device`` parameter, which defaults to 0 when "CUDA" is specified(the first device reported by CUDA
26
+
runtime).
26
27
27
28
28
29
The GPU algorithms currently work with CLI, Python, R, and JVM packages. See :doc:`/install` for details.
Copy file name to clipboardExpand all lines: doc/parameter.rst
+20-19
Original file line number
Diff line number
Diff line change
@@ -59,6 +59,18 @@ General Parameters
59
59
60
60
- Feature dimension used in boosting, set to maximum dimension of the feature
61
61
62
+
* ``device`` [default= ``cpu``]
63
+
64
+
.. versionadded:: 2.0.0
65
+
66
+
- Device for XGBoost to run. User can set it to one of the following values:
67
+
68
+
+ ``cpu``: Use CPU.
69
+
+ ``cuda``: Use a GPU (CUDA device).
70
+
+ ``cuda:<ordinal>``: ``<ordinal>`` is an integer that specifies the ordinal of the GPU (which GPU do you want to use if you have more than one devices).
71
+
+ ``gpu``: Default GPU device selection from the list of available and supported devices. Only ``cuda`` devices are supported currently.
72
+
+ ``gpu:<ordinal>``: Default GPU device selection from the list of available and supported devices. Only ``cuda`` devices are supported currently.
73
+
62
74
Parameters for Tree Booster
63
75
===========================
64
76
* ``eta`` [default=0.3, alias: ``learning_rate``]
@@ -99,7 +111,7 @@ Parameters for Tree Booster
99
111
- ``gradient_based``: the selection probability for each training instance is proportional to the
100
112
*regularized absolute value* of gradients (more specifically, :math:`\sqrt{g^2+\lambda h^2}`).
101
113
``subsample`` may be set to as low as 0.1 without loss of model accuracy. Note that this
102
-
sampling method is only supported when ``tree_method`` is set to ``gpu_hist``; other tree
114
+
sampling method is only supported when ``tree_method`` is set to ``hist`` and the device is ``cuda``; other tree
- The tree construction algorithm used in XGBoost. See description in the `reference paper <http://arxiv.org/abs/1603.02754>`_ and :doc:`treemethod`.
134
-
- XGBoost supports ``approx``, ``hist`` and ``gpu_hist`` for distributed training. Experimental support for external memory is available for ``approx`` and ``gpu_hist``.
135
-
136
-
- Choices: ``auto``, ``exact``, ``approx``, ``hist``, ``gpu_hist``, this is a
137
-
combination of commonly used updaters. For other updaters like ``refresh``, set the
138
-
parameter ``updater`` directly.
139
-
140
-
- ``auto``: Use heuristic to choose the fastest method.
141
146
142
-
- For small dataset, exact greedy (``exact``) will be used.
143
-
- For larger dataset, approximate algorithm (``approx``) will be chosen. It's
144
-
recommended to try ``hist`` and ``gpu_hist`` for higher performance with large
145
-
dataset.
146
-
(``gpu_hist``)has support for ``external memory``.
147
+
- Choices: ``auto``, ``exact``, ``approx``, ``hist``, this is a combination of commonly
148
+
used updaters. For other updaters like ``refresh``, set the parameter ``updater``
149
+
directly.
147
150
148
-
- Because old behavior is always use exact greedy in single machine, user will get a
149
-
message when approximate algorithm is chosen to notify this choice.
151
+
- ``auto``: Same as the ``hist`` tree method.
150
152
- ``exact``: Exact greedy algorithm. Enumerates all split candidates.
151
153
- ``approx``: Approximate greedy algorithm using quantile sketch and gradient histogram.
0 commit comments