Unverified Commit fac4afe0 authored by Nikita Titov's avatar Nikita Titov Committed by GitHub
Browse files

[docs] Added permalink to each param (#1498)

* added permalink to each parameter

* run parameter_generator.py

* concretized links

* hotfix

* run parameter_generator.py

* added space between param name and permalink

* added info about initscore_filename in Continued Training section and edited links

* replaced aliases for weight and group with original names

* disable emoji
parent 9187c75f
...@@ -201,9 +201,9 @@ LightGBM supports the following metrics: ...@@ -201,9 +201,9 @@ LightGBM supports the following metrics:
- MAP - MAP
- Multi class log loss - Multi-class log loss
- Multi class error rate - Multi-class error rate
- Fair - Fair
......
.. List of parameters is auto generated by LightGBM\helper\parameter_generator.py from LightGBM\include\LightGBM\config.h file. .. List of parameters is auto generated by LightGBM\helper\parameter_generator.py from LightGBM\include\LightGBM\config.h file.
.. role:: raw-html(raw)
:format: html
Parameters Parameters
========== ==========
...@@ -30,13 +33,13 @@ If one parameter appears in both command line and config file, LightGBM will use ...@@ -30,13 +33,13 @@ If one parameter appears in both command line and config file, LightGBM will use
Core Parameters Core Parameters
--------------- ---------------
- ``config``, default = ``""``, type = string, aliases: ``config_file`` - ``config`` :raw-html:`<a id="config" title="Permalink to this parameter" href="#config">&#x1F517;&#xFE0E;</a>`, default = ``""``, type = string, aliases: ``config_file``
- path of config file - path of config file
- **Note**: can be used only in CLI version - **Note**: can be used only in CLI version
- ``task``, default = ``train``, type = enum, options: ``train``, ``predict``, ``convert_model``, ``refit``, aliases: ``task_type`` - ``task`` :raw-html:`<a id="task" title="Permalink to this parameter" href="#task">&#x1F517;&#xFE0E;</a>`, default = ``train``, type = enum, options: ``train``, ``predict``, ``convert_model``, ``refit``, aliases: ``task_type``
- ``train``, for training, aliases: ``training`` - ``train``, for training, aliases: ``training``
...@@ -48,7 +51,7 @@ Core Parameters ...@@ -48,7 +51,7 @@ Core Parameters
- **Note**: can be used only in CLI version - **Note**: can be used only in CLI version
- ``objective``, default = ``regression``, type = enum, options: ``regression``, ``regression_l1``, ``huber``, ``fair``, ``poisson``, ``quantile``, ``mape``, ``gammma``, ``tweedie``, ``binary``, ``multiclass``, ``multiclassova``, ``xentropy``, ``xentlambda``, ``lambdarank``, aliases: ``objective_type``, ``app``, ``application`` - ``objective`` :raw-html:`<a id="objective" title="Permalink to this parameter" href="#objective">&#x1F517;&#xFE0E;</a>`, default = ``regression``, type = enum, options: ``regression``, ``regression_l1``, ``huber``, ``fair``, ``poisson``, ``quantile``, ``mape``, ``gammma``, ``tweedie``, ``binary``, ``multiclass``, ``multiclassova``, ``xentropy``, ``xentlambda``, ``lambdarank``, aliases: ``objective_type``, ``app``, ``application``
- regression application - regression application
...@@ -96,7 +99,7 @@ Core Parameters ...@@ -96,7 +99,7 @@ Core Parameters
- all values in ``label`` must be smaller than number of elements in ``label_gain`` - all values in ``label`` must be smaller than number of elements in ``label_gain``
- ``boosting``, default = ``gbdt``, type = enum, options: ``gbdt``, ``gbrt``, ``rf``, ``random_forest``, ``dart``, ``goss``, aliases: ``boosting_type``, ``boost`` - ``boosting`` :raw-html:`<a id="boosting" title="Permalink to this parameter" href="#boosting">&#x1F517;&#xFE0E;</a>`, default = ``gbdt``, type = enum, options: ``gbdt``, ``gbrt``, ``rf``, ``random_forest``, ``dart``, ``goss``, aliases: ``boosting_type``, ``boost``
- ``gbdt``, traditional Gradient Boosting Decision Tree, aliases: ``gbrt`` - ``gbdt``, traditional Gradient Boosting Decision Tree, aliases: ``gbrt``
...@@ -106,13 +109,13 @@ Core Parameters ...@@ -106,13 +109,13 @@ Core Parameters
- ``goss``, Gradient-based One-Side Sampling - ``goss``, Gradient-based One-Side Sampling
- ``data``, default = ``""``, type = string, aliases: ``train``, ``train_data``, ``data_filename`` - ``data`` :raw-html:`<a id="data" title="Permalink to this parameter" href="#data">&#x1F517;&#xFE0E;</a>`, default = ``""``, type = string, aliases: ``train``, ``train_data``, ``data_filename``
- path of training data, LightGBM will train from this data - path of training data, LightGBM will train from this data
- **Note**: can be used only in CLI version - **Note**: can be used only in CLI version
- ``valid``, default = ``""``, type = string, aliases: ``test``, ``valid_data``, ``valid_data_file``, ``test_data``, ``valid_filenames`` - ``valid`` :raw-html:`<a id="valid" title="Permalink to this parameter" href="#valid">&#x1F517;&#xFE0E;</a>`, default = ``""``, type = string, aliases: ``test``, ``valid_data``, ``valid_data_file``, ``test_data``, ``valid_filenames``
- path(s) of validation/test data, LightGBM will output metrics for these data - path(s) of validation/test data, LightGBM will output metrics for these data
...@@ -120,7 +123,7 @@ Core Parameters ...@@ -120,7 +123,7 @@ Core Parameters
- **Note**: can be used only in CLI version - **Note**: can be used only in CLI version
- ``num_iterations``, default = ``100``, type = int, aliases: ``num_iteration``, ``num_tree``, ``num_trees``, ``num_round``, ``num_rounds``, ``num_boost_round``, ``n_estimators``, constraints: ``num_iterations >= 0`` - ``num_iterations`` :raw-html:`<a id="num_iterations" title="Permalink to this parameter" href="#num_iterations">&#x1F517;&#xFE0E;</a>`, default = ``100``, type = int, aliases: ``num_iteration``, ``num_tree``, ``num_trees``, ``num_round``, ``num_rounds``, ``num_boost_round``, ``n_estimators``, constraints: ``num_iterations >= 0``
- number of boosting iterations - number of boosting iterations
...@@ -128,17 +131,17 @@ Core Parameters ...@@ -128,17 +131,17 @@ Core Parameters
- **Note**: internally, LightGBM constructs ``num_class * num_iterations`` trees for multi-class classification problems - **Note**: internally, LightGBM constructs ``num_class * num_iterations`` trees for multi-class classification problems
- ``learning_rate``, default = ``0.1``, type = double, aliases: ``shrinkage_rate``, constraints: ``learning_rate > 0.0`` - ``learning_rate`` :raw-html:`<a id="learning_rate" title="Permalink to this parameter" href="#learning_rate">&#x1F517;&#xFE0E;</a>`, default = ``0.1``, type = double, aliases: ``shrinkage_rate``, constraints: ``learning_rate > 0.0``
- shrinkage rate - shrinkage rate
- in ``dart``, it also affects on normalization weights of dropped trees - in ``dart``, it also affects on normalization weights of dropped trees
- ``num_leaves``, default = ``31``, type = int, aliases: ``num_leaf``, constraints: ``num_leaves > 1`` - ``num_leaves`` :raw-html:`<a id="num_leaves" title="Permalink to this parameter" href="#num_leaves">&#x1F517;&#xFE0E;</a>`, default = ``31``, type = int, aliases: ``num_leaf``, constraints: ``num_leaves > 1``
- max number of leaves in one tree - max number of leaves in one tree
- ``tree_learner``, default = ``serial``, type = enum, options: ``serial``, ``feature``, ``data``, ``voting``, aliases: ``tree``, ``tree_learner_type`` - ``tree_learner`` :raw-html:`<a id="tree_learner" title="Permalink to this parameter" href="#tree_learner">&#x1F517;&#xFE0E;</a>`, default = ``serial``, type = enum, options: ``serial``, ``feature``, ``data``, ``voting``, aliases: ``tree``, ``tree_learner_type``
- ``serial``, single machine tree learner - ``serial``, single machine tree learner
...@@ -150,7 +153,7 @@ Core Parameters ...@@ -150,7 +153,7 @@ Core Parameters
- refer to `Parallel Learning Guide <./Parallel-Learning-Guide.rst>`__ to get more details - refer to `Parallel Learning Guide <./Parallel-Learning-Guide.rst>`__ to get more details
- ``num_threads``, default = ``0``, type = int, aliases: ``num_thread``, ``nthread``, ``nthreads`` - ``num_threads`` :raw-html:`<a id="num_threads" title="Permalink to this parameter" href="#num_threads">&#x1F517;&#xFE0E;</a>`, default = ``0``, type = int, aliases: ``num_thread``, ``nthread``, ``nthreads``
- number of threads for LightGBM - number of threads for LightGBM
...@@ -164,7 +167,7 @@ Core Parameters ...@@ -164,7 +167,7 @@ Core Parameters
- for parallel learning, do not use all CPU cores because this will cause poor performance for the network communication - for parallel learning, do not use all CPU cores because this will cause poor performance for the network communication
- ``device_type``, default = ``cpu``, type = enum, options: ``cpu``, ``gpu``, aliases: ``device`` - ``device_type`` :raw-html:`<a id="device_type" title="Permalink to this parameter" href="#device_type">&#x1F517;&#xFE0E;</a>`, default = ``cpu``, type = enum, options: ``cpu``, ``gpu``, aliases: ``device``
- device for the tree learning, you can use GPU to achieve the faster learning - device for the tree learning, you can use GPU to achieve the faster learning
...@@ -174,7 +177,7 @@ Core Parameters ...@@ -174,7 +177,7 @@ Core Parameters
- **Note**: refer to `Installation Guide <./Installation-Guide.rst#build-gpu-version>`__ to build LightGBM with GPU support - **Note**: refer to `Installation Guide <./Installation-Guide.rst#build-gpu-version>`__ to build LightGBM with GPU support
- ``seed``, default = ``0``, type = int, aliases: ``random_seed`` - ``seed`` :raw-html:`<a id="seed" title="Permalink to this parameter" href="#seed">&#x1F517;&#xFE0E;</a>`, default = ``0``, type = int, aliases: ``random_seed``
- this seed is used to generate other seeds, e.g. ``data_random_seed``, ``feature_fraction_seed`` - this seed is used to generate other seeds, e.g. ``data_random_seed``, ``feature_fraction_seed``
...@@ -183,21 +186,21 @@ Core Parameters ...@@ -183,21 +186,21 @@ Core Parameters
Learning Control Parameters Learning Control Parameters
--------------------------- ---------------------------
- ``max_depth``, default = ``-1``, type = int - ``max_depth`` :raw-html:`<a id="max_depth" title="Permalink to this parameter" href="#max_depth">&#x1F517;&#xFE0E;</a>`, default = ``-1``, type = int
- limit the max depth for tree model. This is used to deal with over-fitting when ``#data`` is small. Tree still grows leaf-wise - limit the max depth for tree model. This is used to deal with over-fitting when ``#data`` is small. Tree still grows leaf-wise
- ``< 0`` means no limit - ``< 0`` means no limit
- ``min_data_in_leaf``, default = ``20``, type = int, aliases: ``min_data_per_leaf``, ``min_data``, ``min_child_samples``, constraints: ``min_data_in_leaf >= 0`` - ``min_data_in_leaf`` :raw-html:`<a id="min_data_in_leaf" title="Permalink to this parameter" href="#min_data_in_leaf">&#x1F517;&#xFE0E;</a>`, default = ``20``, type = int, aliases: ``min_data_per_leaf``, ``min_data``, ``min_child_samples``, constraints: ``min_data_in_leaf >= 0``
- minimal number of data in one leaf. Can be used to deal with over-fitting - minimal number of data in one leaf. Can be used to deal with over-fitting
- ``min_sum_hessian_in_leaf``, default = ``1e-3``, type = double, aliases: ``min_sum_hessian_per_leaf``, ``min_sum_hessian``, ``min_hessian``, ``min_child_weight``, constraints: ``min_sum_hessian_in_leaf >= 0.0`` - ``min_sum_hessian_in_leaf`` :raw-html:`<a id="min_sum_hessian_in_leaf" title="Permalink to this parameter" href="#min_sum_hessian_in_leaf">&#x1F517;&#xFE0E;</a>`, default = ``1e-3``, type = double, aliases: ``min_sum_hessian_per_leaf``, ``min_sum_hessian``, ``min_hessian``, ``min_child_weight``, constraints: ``min_sum_hessian_in_leaf >= 0.0``
- minimal sum hessian in one leaf. Like ``min_data_in_leaf``, it can be used to deal with over-fitting - minimal sum hessian in one leaf. Like ``min_data_in_leaf``, it can be used to deal with over-fitting
- ``bagging_fraction``, default = ``1.0``, type = double, aliases: ``sub_row``, ``subsample``, ``bagging``, constraints: ``0.0 < bagging_fraction <= 1.0`` - ``bagging_fraction`` :raw-html:`<a id="bagging_fraction" title="Permalink to this parameter" href="#bagging_fraction">&#x1F517;&#xFE0E;</a>`, default = ``1.0``, type = double, aliases: ``sub_row``, ``subsample``, ``bagging``, constraints: ``0.0 < bagging_fraction <= 1.0``
- like ``feature_fraction``, but this will randomly select part of data without resampling - like ``feature_fraction``, but this will randomly select part of data without resampling
...@@ -207,7 +210,7 @@ Learning Control Parameters ...@@ -207,7 +210,7 @@ Learning Control Parameters
- **Note**: to enable bagging, ``bagging_freq`` should be set to a non zero value as well - **Note**: to enable bagging, ``bagging_freq`` should be set to a non zero value as well
- ``bagging_freq``, default = ``0``, type = int, aliases: ``subsample_freq`` - ``bagging_freq`` :raw-html:`<a id="bagging_freq" title="Permalink to this parameter" href="#bagging_freq">&#x1F517;&#xFE0E;</a>`, default = ``0``, type = int, aliases: ``subsample_freq``
- frequency for bagging - frequency for bagging
...@@ -215,11 +218,11 @@ Learning Control Parameters ...@@ -215,11 +218,11 @@ Learning Control Parameters
- **Note**: to enable bagging, ``bagging_fraction`` should be set to value smaller than ``1.0`` as well - **Note**: to enable bagging, ``bagging_fraction`` should be set to value smaller than ``1.0`` as well
- ``bagging_seed``, default = ``3``, type = int, aliases: ``bagging_fraction_seed`` - ``bagging_seed`` :raw-html:`<a id="bagging_seed" title="Permalink to this parameter" href="#bagging_seed">&#x1F517;&#xFE0E;</a>`, default = ``3``, type = int, aliases: ``bagging_fraction_seed``
- random seed for bagging - random seed for bagging
- ``feature_fraction``, default = ``1.0``, type = double, aliases: ``sub_feature``, ``colsample_bytree``, constraints: ``0.0 < feature_fraction <= 1.0`` - ``feature_fraction`` :raw-html:`<a id="feature_fraction" title="Permalink to this parameter" href="#feature_fraction">&#x1F517;&#xFE0E;</a>`, default = ``1.0``, type = double, aliases: ``sub_feature``, ``colsample_bytree``, constraints: ``0.0 < feature_fraction <= 1.0``
- LightGBM will randomly select part of features on each iteration if ``feature_fraction`` smaller than ``1.0``. For example, if you set it to ``0.8``, LightGBM will select 80% of features before training each tree - LightGBM will randomly select part of features on each iteration if ``feature_fraction`` smaller than ``1.0``. For example, if you set it to ``0.8``, LightGBM will select 80% of features before training each tree
...@@ -227,17 +230,17 @@ Learning Control Parameters ...@@ -227,17 +230,17 @@ Learning Control Parameters
- can be used to deal with over-fitting - can be used to deal with over-fitting
- ``feature_fraction_seed``, default = ``2``, type = int - ``feature_fraction_seed`` :raw-html:`<a id="feature_fraction_seed" title="Permalink to this parameter" href="#feature_fraction_seed">&#x1F517;&#xFE0E;</a>`, default = ``2``, type = int
- random seed for ``feature_fraction`` - random seed for ``feature_fraction``
- ``early_stopping_round``, default = ``0``, type = int, aliases: ``early_stopping_rounds``, ``early_stopping`` - ``early_stopping_round`` :raw-html:`<a id="early_stopping_round" title="Permalink to this parameter" href="#early_stopping_round">&#x1F517;&#xFE0E;</a>`, default = ``0``, type = int, aliases: ``early_stopping_rounds``, ``early_stopping``
- will stop training if one metric of one validation data doesn't improve in last ``early_stopping_round`` rounds - will stop training if one metric of one validation data doesn't improve in last ``early_stopping_round`` rounds
- ``<= 0`` means disable - ``<= 0`` means disable
- ``max_delta_step``, default = ``0.0``, type = double, aliases: ``max_tree_output``, ``max_leaf_output`` - ``max_delta_step`` :raw-html:`<a id="max_delta_step" title="Permalink to this parameter" href="#max_delta_step">&#x1F517;&#xFE0E;</a>`, default = ``0.0``, type = double, aliases: ``max_tree_output``, ``max_leaf_output``
- used to limit the max output of tree leaves - used to limit the max output of tree leaves
...@@ -245,25 +248,25 @@ Learning Control Parameters ...@@ -245,25 +248,25 @@ Learning Control Parameters
- the final max output of leaves is ``learning_rate * max_delta_step`` - the final max output of leaves is ``learning_rate * max_delta_step``
- ``lambda_l1``, default = ``0.0``, type = double, aliases: ``reg_alpha``, constraints: ``lambda_l1 >= 0.0`` - ``lambda_l1`` :raw-html:`<a id="lambda_l1" title="Permalink to this parameter" href="#lambda_l1">&#x1F517;&#xFE0E;</a>`, default = ``0.0``, type = double, aliases: ``reg_alpha``, constraints: ``lambda_l1 >= 0.0``
- L1 regularization - L1 regularization
- ``lambda_l2``, default = ``0.0``, type = double, aliases: ``reg_lambda``, constraints: ``lambda_l2 >= 0.0`` - ``lambda_l2`` :raw-html:`<a id="lambda_l2" title="Permalink to this parameter" href="#lambda_l2">&#x1F517;&#xFE0E;</a>`, default = ``0.0``, type = double, aliases: ``reg_lambda``, constraints: ``lambda_l2 >= 0.0``
- L2 regularization - L2 regularization
- ``min_gain_to_split``, default = ``0.0``, type = double, aliases: ``min_split_gain``, constraints: ``min_gain_to_split >= 0.0`` - ``min_gain_to_split`` :raw-html:`<a id="min_gain_to_split" title="Permalink to this parameter" href="#min_gain_to_split">&#x1F517;&#xFE0E;</a>`, default = ``0.0``, type = double, aliases: ``min_split_gain``, constraints: ``min_gain_to_split >= 0.0``
- the minimal gain to perform split - the minimal gain to perform split
- ``drop_rate``, default = ``0.1``, type = double, constraints: ``0.0 <= drop_rate <= 1.0`` - ``drop_rate`` :raw-html:`<a id="drop_rate" title="Permalink to this parameter" href="#drop_rate">&#x1F517;&#xFE0E;</a>`, default = ``0.1``, type = double, constraints: ``0.0 <= drop_rate <= 1.0``
- used only in ``dart`` - used only in ``dart``
- dropout rate - dropout rate
- ``max_drop``, default = ``50``, type = int - ``max_drop`` :raw-html:`<a id="max_drop" title="Permalink to this parameter" href="#max_drop">&#x1F517;&#xFE0E;</a>`, default = ``50``, type = int
- used only in ``dart`` - used only in ``dart``
...@@ -271,75 +274,75 @@ Learning Control Parameters ...@@ -271,75 +274,75 @@ Learning Control Parameters
- ``<=0`` means no limit - ``<=0`` means no limit
- ``skip_drop``, default = ``0.5``, type = double, constraints: ``0.0 <= skip_drop <= 1.0`` - ``skip_drop`` :raw-html:`<a id="skip_drop" title="Permalink to this parameter" href="#skip_drop">&#x1F517;&#xFE0E;</a>`, default = ``0.5``, type = double, constraints: ``0.0 <= skip_drop <= 1.0``
- used only in ``dart`` - used only in ``dart``
- probability of skipping drop - probability of skipping drop
- ``xgboost_dart_mode``, default = ``false``, type = bool - ``xgboost_dart_mode`` :raw-html:`<a id="xgboost_dart_mode" title="Permalink to this parameter" href="#xgboost_dart_mode">&#x1F517;&#xFE0E;</a>`, default = ``false``, type = bool
- used only in ``dart`` - used only in ``dart``
- set this to ``true``, if you want to use xgboost dart mode - set this to ``true``, if you want to use xgboost dart mode
- ``uniform_drop``, default = ``false``, type = bool - ``uniform_drop`` :raw-html:`<a id="uniform_drop" title="Permalink to this parameter" href="#uniform_drop">&#x1F517;&#xFE0E;</a>`, default = ``false``, type = bool
- used only in ``dart`` - used only in ``dart``
- set this to ``true``, if you want to use uniform drop - set this to ``true``, if you want to use uniform drop
- ``drop_seed``, default = ``4``, type = int - ``drop_seed`` :raw-html:`<a id="drop_seed" title="Permalink to this parameter" href="#drop_seed">&#x1F517;&#xFE0E;</a>`, default = ``4``, type = int
- used only in ``dart`` - used only in ``dart``
- random seed to choose dropping models - random seed to choose dropping models
- ``top_rate``, default = ``0.2``, type = double, constraints: ``0.0 <= top_rate <= 1.0`` - ``top_rate`` :raw-html:`<a id="top_rate" title="Permalink to this parameter" href="#top_rate">&#x1F517;&#xFE0E;</a>`, default = ``0.2``, type = double, constraints: ``0.0 <= top_rate <= 1.0``
- used only in ``goss`` - used only in ``goss``
- the retain ratio of large gradient data - the retain ratio of large gradient data
- ``other_rate``, default = ``0.1``, type = double, constraints: ``0.0 <= other_rate <= 1.0`` - ``other_rate`` :raw-html:`<a id="other_rate" title="Permalink to this parameter" href="#other_rate">&#x1F517;&#xFE0E;</a>`, default = ``0.1``, type = double, constraints: ``0.0 <= other_rate <= 1.0``
- used only in ``goss`` - used only in ``goss``
- the retain ratio of small gradient data - the retain ratio of small gradient data
- ``min_data_per_group``, default = ``100``, type = int, constraints: ``min_data_per_group > 0`` - ``min_data_per_group`` :raw-html:`<a id="min_data_per_group" title="Permalink to this parameter" href="#min_data_per_group">&#x1F517;&#xFE0E;</a>`, default = ``100``, type = int, constraints: ``min_data_per_group > 0``
- minimal number of data per categorical group - minimal number of data per categorical group
- ``max_cat_threshold``, default = ``32``, type = int, constraints: ``max_cat_threshold > 0`` - ``max_cat_threshold`` :raw-html:`<a id="max_cat_threshold" title="Permalink to this parameter" href="#max_cat_threshold">&#x1F517;&#xFE0E;</a>`, default = ``32``, type = int, constraints: ``max_cat_threshold > 0``
- used for the categorical features - used for the categorical features
- limit the max threshold points in categorical features - limit the max threshold points in categorical features
- ``cat_l2``, default = ``10.0``, type = double, constraints: ``cat_l2 >= 0.0`` - ``cat_l2`` :raw-html:`<a id="cat_l2" title="Permalink to this parameter" href="#cat_l2">&#x1F517;&#xFE0E;</a>`, default = ``10.0``, type = double, constraints: ``cat_l2 >= 0.0``
- used for the categorical features - used for the categorical features
- L2 regularization in categorcial split - L2 regularization in categorcial split
- ``cat_smooth``, default = ``10.0``, type = double, constraints: ``cat_smooth >= 0.0`` - ``cat_smooth`` :raw-html:`<a id="cat_smooth" title="Permalink to this parameter" href="#cat_smooth">&#x1F517;&#xFE0E;</a>`, default = ``10.0``, type = double, constraints: ``cat_smooth >= 0.0``
- used for the categorical features - used for the categorical features
- this can reduce the effect of noises in categorical features, especially for categories with few data - this can reduce the effect of noises in categorical features, especially for categories with few data
- ``max_cat_to_onehot``, default = ``4``, type = int, constraints: ``max_cat_to_onehot > 0`` - ``max_cat_to_onehot`` :raw-html:`<a id="max_cat_to_onehot" title="Permalink to this parameter" href="#max_cat_to_onehot">&#x1F517;&#xFE0E;</a>`, default = ``4``, type = int, constraints: ``max_cat_to_onehot > 0``
- when number of categories of one feature smaller than or equal to ``max_cat_to_onehot``, one-vs-other split algorithm will be used - when number of categories of one feature smaller than or equal to ``max_cat_to_onehot``, one-vs-other split algorithm will be used
- ``top_k``, default = ``20``, type = int, aliases: ``topk``, constraints: ``top_k > 0`` - ``top_k`` :raw-html:`<a id="top_k" title="Permalink to this parameter" href="#top_k">&#x1F517;&#xFE0E;</a>`, default = ``20``, type = int, aliases: ``topk``, constraints: ``top_k > 0``
- used in `Voting parallel <./Parallel-Learning-Guide.rst#choose-appropriate-parallel-algorithm>`__ - used in `Voting parallel <./Parallel-Learning-Guide.rst#choose-appropriate-parallel-algorithm>`__
- set this to larger value for more accurate result, but it will slow down the training speed - set this to larger value for more accurate result, but it will slow down the training speed
- ``monotone_constraints``, default = ``None``, type = multi-int, aliases: ``mc``, ``monotone_constraint`` - ``monotone_constraints`` :raw-html:`<a id="monotone_constraints" title="Permalink to this parameter" href="#monotone_constraints">&#x1F517;&#xFE0E;</a>`, default = ``None``, type = multi-int, aliases: ``mc``, ``monotone_constraint``
- used for constraints of monotonic features - used for constraints of monotonic features
...@@ -347,13 +350,13 @@ Learning Control Parameters ...@@ -347,13 +350,13 @@ Learning Control Parameters
- you need to specify all features in order. For example, ``mc=-1,0,1`` means decreasing for 1st feature, non-constraint for 2nd feature and increasing for the 3rd feature - you need to specify all features in order. For example, ``mc=-1,0,1`` means decreasing for 1st feature, non-constraint for 2nd feature and increasing for the 3rd feature
- ``feature_contri``, default = ``None``, type = multi-double, aliases: ``fc``, ``fp``, ``feature_penalty`` - ``feature_contri`` :raw-html:`<a id="feature_contri" title="Permalink to this parameter" href="#feature_contri">&#x1F517;&#xFE0E;</a>`, default = ``None``, type = multi-double, aliases: ``fc``, ``fp``, ``feature_penalty``
- used to control feature's split gain, will use ``gain[i] = max(0, feature_contri[i]) * gain[i]`` to replace the split gain of i-th feature - used to control feature's split gain, will use ``gain[i] = max(0, feature_contri[i]) * gain[i]`` to replace the split gain of i-th feature
- you need to specify all features in order - you need to specify all features in order
- ``forcedsplits_filename``, default = ``""``, type = string, aliases: ``fs``, ``forced_splits_filename``, ``forced_splits_file``, ``forced_splits`` - ``forcedsplits_filename`` :raw-html:`<a id="forcedsplits_filename" title="Permalink to this parameter" href="#forcedsplits_filename">&#x1F517;&#xFE0E;</a>`, default = ``""``, type = string, aliases: ``fs``, ``forced_splits_filename``, ``forced_splits_file``, ``forced_splits``
- path to a ``.json`` file that specifies splits to force at the top of every decision tree before best-first learning commences - path to a ``.json`` file that specifies splits to force at the top of every decision tree before best-first learning commences
...@@ -366,13 +369,13 @@ Learning Control Parameters ...@@ -366,13 +369,13 @@ Learning Control Parameters
IO Parameters IO Parameters
------------- -------------
- ``verbosity``, default = ``1``, type = int, aliases: ``verbose`` - ``verbosity`` :raw-html:`<a id="verbosity" title="Permalink to this parameter" href="#verbosity">&#x1F517;&#xFE0E;</a>`, default = ``1``, type = int, aliases: ``verbose``
- controls the level of LightGBM's verbosity - controls the level of LightGBM's verbosity
- ``< 0``: Fatal, ``= 0``: Error (Warn), ``> 0``: Info - ``< 0``: Fatal, ``= 0``: Error (Warn), ``> 0``: Info
- ``max_bin``, default = ``255``, type = int, constraints: ``max_bin > 1`` - ``max_bin`` :raw-html:`<a id="max_bin" title="Permalink to this parameter" href="#max_bin">&#x1F517;&#xFE0E;</a>`, default = ``255``, type = int, constraints: ``max_bin > 1``
- max number of bins that feature values will be bucketed in - max number of bins that feature values will be bucketed in
...@@ -380,13 +383,13 @@ IO Parameters ...@@ -380,13 +383,13 @@ IO Parameters
- LightGBM will auto compress memory according to ``max_bin``. For example, LightGBM will use ``uint8_t`` for feature value if ``max_bin=255`` - LightGBM will auto compress memory according to ``max_bin``. For example, LightGBM will use ``uint8_t`` for feature value if ``max_bin=255``
- ``min_data_in_bin``, default = ``3``, type = int, constraints: ``min_data_in_bin > 0`` - ``min_data_in_bin`` :raw-html:`<a id="min_data_in_bin" title="Permalink to this parameter" href="#min_data_in_bin">&#x1F517;&#xFE0E;</a>`, default = ``3``, type = int, constraints: ``min_data_in_bin > 0``
- minimal number of data inside one bin - minimal number of data inside one bin
- use this to avoid one-data-one-bin (potential over-fitting) - use this to avoid one-data-one-bin (potential over-fitting)
- ``bin_construct_sample_cnt``, default = ``200000``, type = int, aliases: ``subsample_for_bin``, constraints: ``bin_construct_sample_cnt > 0`` - ``bin_construct_sample_cnt`` :raw-html:`<a id="bin_construct_sample_cnt" title="Permalink to this parameter" href="#bin_construct_sample_cnt">&#x1F517;&#xFE0E;</a>`, default = ``200000``, type = int, aliases: ``subsample_for_bin``, constraints: ``bin_construct_sample_cnt > 0``
- number of data that sampled to construct histogram bins - number of data that sampled to construct histogram bins
...@@ -394,23 +397,23 @@ IO Parameters ...@@ -394,23 +397,23 @@ IO Parameters
- set this to larger value if data is very sparse - set this to larger value if data is very sparse
- ``histogram_pool_size``, default = ``-1.0``, type = double - ``histogram_pool_size`` :raw-html:`<a id="histogram_pool_size" title="Permalink to this parameter" href="#histogram_pool_size">&#x1F517;&#xFE0E;</a>`, default = ``-1.0``, type = double
- max cache size in MB for historical histogram - max cache size in MB for historical histogram
- ``< 0`` means no limit - ``< 0`` means no limit
- ``data_random_seed``, default = ``1``, type = int - ``data_random_seed`` :raw-html:`<a id="data_random_seed" title="Permalink to this parameter" href="#data_random_seed">&#x1F517;&#xFE0E;</a>`, default = ``1``, type = int
- random seed for data partition in parallel learning (excluding the ``feature_parallel`` mode) - random seed for data partition in parallel learning (excluding the ``feature_parallel`` mode)
- ``output_model``, default = ``LightGBM_model.txt``, type = string, aliases: ``model_output``, ``model_out`` - ``output_model`` :raw-html:`<a id="output_model" title="Permalink to this parameter" href="#output_model">&#x1F517;&#xFE0E;</a>`, default = ``LightGBM_model.txt``, type = string, aliases: ``model_output``, ``model_out``
- filename of output model in training - filename of output model in training
- **Note**: can be used only in CLI version - **Note**: can be used only in CLI version
- ``snapshot_freq``, default = ``-1``, type = int - ``snapshot_freq`` :raw-html:`<a id="snapshot_freq" title="Permalink to this parameter" href="#snapshot_freq">&#x1F517;&#xFE0E;</a>`, default = ``-1``, type = int
- frequency of saving model file snapshot - frequency of saving model file snapshot
...@@ -418,7 +421,7 @@ IO Parameters ...@@ -418,7 +421,7 @@ IO Parameters
- **Note**: can be used only in CLI version - **Note**: can be used only in CLI version
- ``input_model``, default = ``""``, type = string, aliases: ``model_input``, ``model_in`` - ``input_model`` :raw-html:`<a id="input_model" title="Permalink to this parameter" href="#input_model">&#x1F517;&#xFE0E;</a>`, default = ``""``, type = string, aliases: ``model_input``, ``model_in``
- filename of input model - filename of input model
...@@ -428,13 +431,13 @@ IO Parameters ...@@ -428,13 +431,13 @@ IO Parameters
- **Note**: can be used only in CLI version - **Note**: can be used only in CLI version
- ``output_result``, default = ``LightGBM_predict_result.txt``, type = string, aliases: ``predict_result``, ``prediction_result`` - ``output_result`` :raw-html:`<a id="output_result" title="Permalink to this parameter" href="#output_result">&#x1F517;&#xFE0E;</a>`, default = ``LightGBM_predict_result.txt``, type = string, aliases: ``predict_result``, ``prediction_result``
- filename of prediction result in ``prediction`` task - filename of prediction result in ``prediction`` task
- **Note**: can be used only in CLI version - **Note**: can be used only in CLI version
- ``initscore_filename``, default = ``""``, type = string, aliases: ``init_score_filename``, ``init_score_file``, ``init_score``, ``input_init_score`` - ``initscore_filename`` :raw-html:`<a id="initscore_filename" title="Permalink to this parameter" href="#initscore_filename">&#x1F517;&#xFE0E;</a>`, default = ``""``, type = string, aliases: ``init_score_filename``, ``init_score_file``, ``init_score``, ``input_init_score``
- path of file with training initial scores - path of file with training initial scores
...@@ -442,7 +445,7 @@ IO Parameters ...@@ -442,7 +445,7 @@ IO Parameters
- **Note**: can be used only in CLI version - **Note**: can be used only in CLI version
- ``valid_data_initscores``, default = ``""``, type = string, aliases: ``valid_data_init_scores``, ``valid_init_score_file``, ``valid_init_score`` - ``valid_data_initscores`` :raw-html:`<a id="valid_data_initscores" title="Permalink to this parameter" href="#valid_data_initscores">&#x1F517;&#xFE0E;</a>`, default = ``""``, type = string, aliases: ``valid_data_init_scores``, ``valid_init_score_file``, ``valid_init_score``
- path(s) of file(s) with validation initial scores - path(s) of file(s) with validation initial scores
...@@ -452,19 +455,19 @@ IO Parameters ...@@ -452,19 +455,19 @@ IO Parameters
- **Note**: can be used only in CLI version - **Note**: can be used only in CLI version
- ``pre_partition``, default = ``false``, type = bool, aliases: ``is_pre_partition`` - ``pre_partition`` :raw-html:`<a id="pre_partition" title="Permalink to this parameter" href="#pre_partition">&#x1F517;&#xFE0E;</a>`, default = ``false``, type = bool, aliases: ``is_pre_partition``
- used for parallel learning (excluding the ``feature_parallel`` mode) - used for parallel learning (excluding the ``feature_parallel`` mode)
- ``true`` if training data are pre-partitioned, and different machines use different partitions - ``true`` if training data are pre-partitioned, and different machines use different partitions
- ``enable_bundle``, default = ``true``, type = bool, aliases: ``is_enable_bundle``, ``bundle`` - ``enable_bundle`` :raw-html:`<a id="enable_bundle" title="Permalink to this parameter" href="#enable_bundle">&#x1F517;&#xFE0E;</a>`, default = ``true``, type = bool, aliases: ``is_enable_bundle``, ``bundle``
- set this to ``false`` to disable Exclusive Feature Bundling (EFB), which is described in `LightGBM: A Highly Efficient Gradient Boosting Decision Tree <https://papers.nips.cc/paper/6907-lightgbm-a-highly-efficient-gradient-boosting-decision-tree>`__ - set this to ``false`` to disable Exclusive Feature Bundling (EFB), which is described in `LightGBM: A Highly Efficient Gradient Boosting Decision Tree <https://papers.nips.cc/paper/6907-lightgbm-a-highly-efficient-gradient-boosting-decision-tree>`__
- **Note**: disabling this may cause the slow training speed for sparse datasets - **Note**: disabling this may cause the slow training speed for sparse datasets
- ``max_conflict_rate``, default = ``0.0``, type = double, constraints: ``0.0 <= max_conflict_rate < 1.0`` - ``max_conflict_rate`` :raw-html:`<a id="max_conflict_rate" title="Permalink to this parameter" href="#max_conflict_rate">&#x1F517;&#xFE0E;</a>`, default = ``0.0``, type = double, constraints: ``0.0 <= max_conflict_rate < 1.0``
- max conflict rate for bundles in EFB - max conflict rate for bundles in EFB
...@@ -472,45 +475,45 @@ IO Parameters ...@@ -472,45 +475,45 @@ IO Parameters
- set this to a larger value to achieve faster speed - set this to a larger value to achieve faster speed
- ``is_enable_sparse``, default = ``true``, type = bool, aliases: ``is_sparse``, ``enable_sparse``, ``sparse`` - ``is_enable_sparse`` :raw-html:`<a id="is_enable_sparse" title="Permalink to this parameter" href="#is_enable_sparse">&#x1F517;&#xFE0E;</a>`, default = ``true``, type = bool, aliases: ``is_sparse``, ``enable_sparse``, ``sparse``
- used to enable/disable sparse optimization - used to enable/disable sparse optimization
- ``sparse_threshold``, default = ``0.8``, type = double, constraints: ``0.0 < sparse_threshold <= 1.0`` - ``sparse_threshold`` :raw-html:`<a id="sparse_threshold" title="Permalink to this parameter" href="#sparse_threshold">&#x1F517;&#xFE0E;</a>`, default = ``0.8``, type = double, constraints: ``0.0 < sparse_threshold <= 1.0``
- the threshold of zero elements precentage for treating a feature as a sparse one - the threshold of zero elements precentage for treating a feature as a sparse one
- ``use_missing``, default = ``true``, type = bool - ``use_missing`` :raw-html:`<a id="use_missing" title="Permalink to this parameter" href="#use_missing">&#x1F517;&#xFE0E;</a>`, default = ``true``, type = bool
- set this to ``false`` to disable the special handle of missing value - set this to ``false`` to disable the special handle of missing value
- ``zero_as_missing``, default = ``false``, type = bool - ``zero_as_missing`` :raw-html:`<a id="zero_as_missing" title="Permalink to this parameter" href="#zero_as_missing">&#x1F517;&#xFE0E;</a>`, default = ``false``, type = bool
- set this to ``true`` to treat all zero as missing values (including the unshown values in libsvm/sparse matrics) - set this to ``true`` to treat all zero as missing values (including the unshown values in libsvm/sparse matrics)
- set this to ``false`` to use ``na`` for representing missing values - set this to ``false`` to use ``na`` for representing missing values
- ``two_round``, default = ``false``, type = bool, aliases: ``two_round_loading``, ``use_two_round_loading`` - ``two_round`` :raw-html:`<a id="two_round" title="Permalink to this parameter" href="#two_round">&#x1F517;&#xFE0E;</a>`, default = ``false``, type = bool, aliases: ``two_round_loading``, ``use_two_round_loading``
- set this to ``true`` if data file is too big to fit in memory - set this to ``true`` if data file is too big to fit in memory
- by default, LightGBM will map data file to memory and load features from memory. This will provide faster data loading speed, but may cause run out of memory error when the data file is very big - by default, LightGBM will map data file to memory and load features from memory. This will provide faster data loading speed, but may cause run out of memory error when the data file is very big
- ``save_binary``, default = ``false``, type = bool, aliases: ``is_save_binary``, ``is_save_binary_file`` - ``save_binary`` :raw-html:`<a id="save_binary" title="Permalink to this parameter" href="#save_binary">&#x1F517;&#xFE0E;</a>`, default = ``false``, type = bool, aliases: ``is_save_binary``, ``is_save_binary_file``
- if ``true``, LightGBM will save the dataset (including validation data) to a binary file. This speed ups the data loading for the next time - if ``true``, LightGBM will save the dataset (including validation data) to a binary file. This speed ups the data loading for the next time
- ``enable_load_from_binary_file``, default = ``true``, type = bool, aliases: ``load_from_binary_file``, ``binary_load``, ``load_binary`` - ``enable_load_from_binary_file`` :raw-html:`<a id="enable_load_from_binary_file" title="Permalink to this parameter" href="#enable_load_from_binary_file">&#x1F517;&#xFE0E;</a>`, default = ``true``, type = bool, aliases: ``load_from_binary_file``, ``binary_load``, ``load_binary``
- set this to ``true`` to enable autoloading from previous saved binary datasets - set this to ``true`` to enable autoloading from previous saved binary datasets
- set this to ``false`` to ignore binary datasets - set this to ``false`` to ignore binary datasets
- ``header``, default = ``false``, type = bool, aliases: ``has_header`` - ``header`` :raw-html:`<a id="header" title="Permalink to this parameter" href="#header">&#x1F517;&#xFE0E;</a>`, default = ``false``, type = bool, aliases: ``has_header``
- set this to ``true`` if input data has header - set this to ``true`` if input data has header
- ``label_column``, default = ``""``, type = int or string, aliases: ``label`` - ``label_column`` :raw-html:`<a id="label_column" title="Permalink to this parameter" href="#label_column">&#x1F517;&#xFE0E;</a>`, default = ``""``, type = int or string, aliases: ``label``
- used to specify the label column - used to specify the label column
...@@ -518,7 +521,7 @@ IO Parameters ...@@ -518,7 +521,7 @@ IO Parameters
- add a prefix ``name:`` for column name, e.g. ``label=name:is_click`` - add a prefix ``name:`` for column name, e.g. ``label=name:is_click``
- ``weight_column``, default = ``""``, type = int or string, aliases: ``weight`` - ``weight_column`` :raw-html:`<a id="weight_column" title="Permalink to this parameter" href="#weight_column">&#x1F517;&#xFE0E;</a>`, default = ``""``, type = int or string, aliases: ``weight``
- used to specify the weight column - used to specify the weight column
...@@ -528,7 +531,7 @@ IO Parameters ...@@ -528,7 +531,7 @@ IO Parameters
- **Note**: index starts from ``0`` and it doesn't count the label column when passing type is ``int``, e.g. when label is column\_0, and weight is column\_1, the correct parameter is ``weight=0`` - **Note**: index starts from ``0`` and it doesn't count the label column when passing type is ``int``, e.g. when label is column\_0, and weight is column\_1, the correct parameter is ``weight=0``
- ``group_column``, default = ``""``, type = int or string, aliases: ``group``, ``group_id``, ``query_column``, ``query``, ``query_id`` - ``group_column`` :raw-html:`<a id="group_column" title="Permalink to this parameter" href="#group_column">&#x1F517;&#xFE0E;</a>`, default = ``""``, type = int or string, aliases: ``group``, ``group_id``, ``query_column``, ``query``, ``query_id``
- used to specify the query/group id column - used to specify the query/group id column
...@@ -540,7 +543,7 @@ IO Parameters ...@@ -540,7 +543,7 @@ IO Parameters
- **Note**: index starts from ``0`` and it doesn't count the label column when passing type is ``int``, e.g. when label is column\_0 and query\_id is column\_1, the correct parameter is ``query=0`` - **Note**: index starts from ``0`` and it doesn't count the label column when passing type is ``int``, e.g. when label is column\_0 and query\_id is column\_1, the correct parameter is ``query=0``
- ``ignore_column``, default = ``""``, type = multi-int or string, aliases: ``ignore_feature``, ``blacklist`` - ``ignore_column`` :raw-html:`<a id="ignore_column" title="Permalink to this parameter" href="#ignore_column">&#x1F517;&#xFE0E;</a>`, default = ``""``, type = multi-int or string, aliases: ``ignore_feature``, ``blacklist``
- used to specify some ignoring columns in training - used to specify some ignoring columns in training
...@@ -552,7 +555,7 @@ IO Parameters ...@@ -552,7 +555,7 @@ IO Parameters
- **Note**: index starts from ``0`` and it doesn't count the label column when passing type is ``int`` - **Note**: index starts from ``0`` and it doesn't count the label column when passing type is ``int``
- ``categorical_feature``, default = ``""``, type = multi-int or string, aliases: ``cat_feature``, ``categorical_column``, ``cat_column`` - ``categorical_feature`` :raw-html:`<a id="categorical_feature" title="Permalink to this parameter" href="#categorical_feature">&#x1F517;&#xFE0E;</a>`, default = ``""``, type = multi-int or string, aliases: ``cat_feature``, ``categorical_column``, ``cat_column``
- used to specify categorical features - used to specify categorical features
...@@ -568,7 +571,7 @@ IO Parameters ...@@ -568,7 +571,7 @@ IO Parameters
- **Note**: the negative values will be treated as **missing values** - **Note**: the negative values will be treated as **missing values**
- ``predict_raw_score``, default = ``false``, type = bool, aliases: ``is_predict_raw_score``, ``predict_rawscore``, ``raw_score`` - ``predict_raw_score`` :raw-html:`<a id="predict_raw_score" title="Permalink to this parameter" href="#predict_raw_score">&#x1F517;&#xFE0E;</a>`, default = ``false``, type = bool, aliases: ``is_predict_raw_score``, ``predict_rawscore``, ``raw_score``
- used only in ``prediction`` task - used only in ``prediction`` task
...@@ -576,13 +579,13 @@ IO Parameters ...@@ -576,13 +579,13 @@ IO Parameters
- set this to ``false`` to predict transformed scores - set this to ``false`` to predict transformed scores
- ``predict_leaf_index``, default = ``false``, type = bool, aliases: ``is_predict_leaf_index``, ``leaf_index`` - ``predict_leaf_index`` :raw-html:`<a id="predict_leaf_index" title="Permalink to this parameter" href="#predict_leaf_index">&#x1F517;&#xFE0E;</a>`, default = ``false``, type = bool, aliases: ``is_predict_leaf_index``, ``leaf_index``
- used only in ``prediction`` task - used only in ``prediction`` task
- set this to ``true`` to predict with leaf index of all trees - set this to ``true`` to predict with leaf index of all trees
- ``predict_contrib``, default = ``false``, type = bool, aliases: ``is_predict_contrib``, ``contrib`` - ``predict_contrib`` :raw-html:`<a id="predict_contrib" title="Permalink to this parameter" href="#predict_contrib">&#x1F517;&#xFE0E;</a>`, default = ``false``, type = bool, aliases: ``is_predict_contrib``, ``contrib``
- used only in ``prediction`` task - used only in ``prediction`` task
...@@ -590,7 +593,7 @@ IO Parameters ...@@ -590,7 +593,7 @@ IO Parameters
- produces ``#features + 1`` values where the last value is the expected value of the model output over the training data - produces ``#features + 1`` values where the last value is the expected value of the model output over the training data
- ``num_iteration_predict``, default = ``-1``, type = int - ``num_iteration_predict`` :raw-html:`<a id="num_iteration_predict" title="Permalink to this parameter" href="#num_iteration_predict">&#x1F517;&#xFE0E;</a>`, default = ``-1``, type = int
- used only in ``prediction`` task - used only in ``prediction`` task
...@@ -598,25 +601,25 @@ IO Parameters ...@@ -598,25 +601,25 @@ IO Parameters
- ``<= 0`` means no limit - ``<= 0`` means no limit
- ``pred_early_stop``, default = ``false``, type = bool - ``pred_early_stop`` :raw-html:`<a id="pred_early_stop" title="Permalink to this parameter" href="#pred_early_stop">&#x1F517;&#xFE0E;</a>`, default = ``false``, type = bool
- used only in ``prediction`` task - used only in ``prediction`` task
- if ``true``, will use early-stopping to speed up the prediction. May affect the accuracy - if ``true``, will use early-stopping to speed up the prediction. May affect the accuracy
- ``pred_early_stop_freq``, default = ``10``, type = int - ``pred_early_stop_freq`` :raw-html:`<a id="pred_early_stop_freq" title="Permalink to this parameter" href="#pred_early_stop_freq">&#x1F517;&#xFE0E;</a>`, default = ``10``, type = int
- used only in ``prediction`` task - used only in ``prediction`` task
- the frequency of checking early-stopping prediction - the frequency of checking early-stopping prediction
- ``pred_early_stop_margin``, default = ``10.0``, type = double - ``pred_early_stop_margin`` :raw-html:`<a id="pred_early_stop_margin" title="Permalink to this parameter" href="#pred_early_stop_margin">&#x1F517;&#xFE0E;</a>`, default = ``10.0``, type = double
- used only in ``prediction`` task - used only in ``prediction`` task
- the threshold of margin in early-stopping prediction - the threshold of margin in early-stopping prediction
- ``convert_model_language``, default = ``""``, type = string - ``convert_model_language`` :raw-html:`<a id="convert_model_language" title="Permalink to this parameter" href="#convert_model_language">&#x1F517;&#xFE0E;</a>`, default = ``""``, type = string
- used only in ``convert_model`` task - used only in ``convert_model`` task
...@@ -626,7 +629,7 @@ IO Parameters ...@@ -626,7 +629,7 @@ IO Parameters
- **Note**: can be used only in CLI version - **Note**: can be used only in CLI version
- ``convert_model``, default = ``gbdt_prediction.cpp``, type = string, aliases: ``convert_model_file`` - ``convert_model`` :raw-html:`<a id="convert_model" title="Permalink to this parameter" href="#convert_model">&#x1F517;&#xFE0E;</a>`, default = ``gbdt_prediction.cpp``, type = string, aliases: ``convert_model_file``
- used only in ``convert_model`` task - used only in ``convert_model`` task
...@@ -637,11 +640,11 @@ IO Parameters ...@@ -637,11 +640,11 @@ IO Parameters
Objective Parameters Objective Parameters
-------------------- --------------------
- ``num_class``, default = ``1``, type = int, aliases: ``num_classes``, constraints: ``num_class > 0`` - ``num_class`` :raw-html:`<a id="num_class" title="Permalink to this parameter" href="#num_class">&#x1F517;&#xFE0E;</a>`, default = ``1``, type = int, aliases: ``num_classes``, constraints: ``num_class > 0``
- used only in ``multi-class`` classification application - used only in ``multi-class`` classification application
- ``is_unbalance``, default = ``false``, type = bool, aliases: ``unbalanced_sets`` - ``is_unbalance`` :raw-html:`<a id="is_unbalance" title="Permalink to this parameter" href="#is_unbalance">&#x1F517;&#xFE0E;</a>`, default = ``false``, type = bool, aliases: ``unbalanced_sets``
- used only in ``binary`` application - used only in ``binary`` application
...@@ -649,7 +652,7 @@ Objective Parameters ...@@ -649,7 +652,7 @@ Objective Parameters
- **Note**: this parameter cannot be used at the same time with ``scale_pos_weight``, choose only **one** of them - **Note**: this parameter cannot be used at the same time with ``scale_pos_weight``, choose only **one** of them
- ``scale_pos_weight``, default = ``1.0``, type = double, constraints: ``scale_pos_weight > 0.0`` - ``scale_pos_weight`` :raw-html:`<a id="scale_pos_weight" title="Permalink to this parameter" href="#scale_pos_weight">&#x1F517;&#xFE0E;</a>`, default = ``1.0``, type = double, constraints: ``scale_pos_weight > 0.0``
- used only in ``binary`` application - used only in ``binary`` application
...@@ -657,19 +660,19 @@ Objective Parameters ...@@ -657,19 +660,19 @@ Objective Parameters
- **Note**: this parameter cannot be used at the same time with ``is_unbalance``, choose only **one** of them - **Note**: this parameter cannot be used at the same time with ``is_unbalance``, choose only **one** of them
- ``sigmoid``, default = ``1.0``, type = double, constraints: ``sigmoid > 0.0`` - ``sigmoid`` :raw-html:`<a id="sigmoid" title="Permalink to this parameter" href="#sigmoid">&#x1F517;&#xFE0E;</a>`, default = ``1.0``, type = double, constraints: ``sigmoid > 0.0``
- used only in ``binary`` and ``multiclassova`` classification and in ``lambdarank`` applications - used only in ``binary`` and ``multiclassova`` classification and in ``lambdarank`` applications
- parameter for the sigmoid function - parameter for the sigmoid function
- ``boost_from_average``, default = ``true``, type = bool - ``boost_from_average`` :raw-html:`<a id="boost_from_average" title="Permalink to this parameter" href="#boost_from_average">&#x1F517;&#xFE0E;</a>`, default = ``true``, type = bool
- used only in ``regression``, ``binary`` and ``cross-entropy`` applications - used only in ``regression``, ``binary`` and ``cross-entropy`` applications
- adjusts initial score to the mean of labels for faster convergence - adjusts initial score to the mean of labels for faster convergence
- ``reg_sqrt``, default = ``false``, type = bool - ``reg_sqrt`` :raw-html:`<a id="reg_sqrt" title="Permalink to this parameter" href="#reg_sqrt">&#x1F517;&#xFE0E;</a>`, default = ``false``, type = bool
- used only in ``regression`` application - used only in ``regression`` application
...@@ -677,25 +680,25 @@ Objective Parameters ...@@ -677,25 +680,25 @@ Objective Parameters
- might be useful in case of large-range labels - might be useful in case of large-range labels
- ``alpha``, default = ``0.9``, type = double, constraints: ``alpha > 0.0`` - ``alpha`` :raw-html:`<a id="alpha" title="Permalink to this parameter" href="#alpha">&#x1F517;&#xFE0E;</a>`, default = ``0.9``, type = double, constraints: ``alpha > 0.0``
- used only in ``huber`` and ``quantile`` ``regression`` applications - used only in ``huber`` and ``quantile`` ``regression`` applications
- parameter for `Huber loss <https://en.wikipedia.org/wiki/Huber_loss>`__ and `Quantile regression <https://en.wikipedia.org/wiki/Quantile_regression>`__ - parameter for `Huber loss <https://en.wikipedia.org/wiki/Huber_loss>`__ and `Quantile regression <https://en.wikipedia.org/wiki/Quantile_regression>`__
- ``fair_c``, default = ``1.0``, type = double, constraints: ``fair_c > 0.0`` - ``fair_c`` :raw-html:`<a id="fair_c" title="Permalink to this parameter" href="#fair_c">&#x1F517;&#xFE0E;</a>`, default = ``1.0``, type = double, constraints: ``fair_c > 0.0``
- used only in ``fair`` ``regression`` application - used only in ``fair`` ``regression`` application
- parameter for `Fair loss <https://www.kaggle.com/c/allstate-claims-severity/discussion/24520>`__ - parameter for `Fair loss <https://www.kaggle.com/c/allstate-claims-severity/discussion/24520>`__
- ``poisson_max_delta_step``, default = ``0.7``, type = double, constraints: ``poisson_max_delta_step > 0.0`` - ``poisson_max_delta_step`` :raw-html:`<a id="poisson_max_delta_step" title="Permalink to this parameter" href="#poisson_max_delta_step">&#x1F517;&#xFE0E;</a>`, default = ``0.7``, type = double, constraints: ``poisson_max_delta_step > 0.0``
- used only in ``poisson`` ``regression`` application - used only in ``poisson`` ``regression`` application
- parameter for `Poisson regression <https://en.wikipedia.org/wiki/Poisson_regression>`__ to safeguard optimization - parameter for `Poisson regression <https://en.wikipedia.org/wiki/Poisson_regression>`__ to safeguard optimization
- ``tweedie_variance_power``, default = ``1.5``, type = double, constraints: ``1.0 <= tweedie_variance_power < 2.0`` - ``tweedie_variance_power`` :raw-html:`<a id="tweedie_variance_power" title="Permalink to this parameter" href="#tweedie_variance_power">&#x1F517;&#xFE0E;</a>`, default = ``1.5``, type = double, constraints: ``1.0 <= tweedie_variance_power < 2.0``
- used only in ``tweedie`` ``regression`` application - used only in ``tweedie`` ``regression`` application
...@@ -705,13 +708,13 @@ Objective Parameters ...@@ -705,13 +708,13 @@ Objective Parameters
- set this closer to ``1`` to shift towards a **Poisson** distribution - set this closer to ``1`` to shift towards a **Poisson** distribution
- ``max_position``, default = ``20``, type = int, constraints: ``max_position > 0`` - ``max_position`` :raw-html:`<a id="max_position" title="Permalink to this parameter" href="#max_position">&#x1F517;&#xFE0E;</a>`, default = ``20``, type = int, constraints: ``max_position > 0``
- used only in ``lambdarank`` application - used only in ``lambdarank`` application
- optimizes `NDCG <https://en.wikipedia.org/wiki/Discounted_cumulative_gain#Normalized_DCG>`__ at this position - optimizes `NDCG <https://en.wikipedia.org/wiki/Discounted_cumulative_gain#Normalized_DCG>`__ at this position
- ``label_gain``, default = ``0,1,3,7,15,31,63,...,2^30-1``, type = multi-double - ``label_gain`` :raw-html:`<a id="label_gain" title="Permalink to this parameter" href="#label_gain">&#x1F517;&#xFE0E;</a>`, default = ``0,1,3,7,15,31,63,...,2^30-1``, type = multi-double
- used only in ``lambdarank`` application - used only in ``lambdarank`` application
...@@ -722,7 +725,7 @@ Objective Parameters ...@@ -722,7 +725,7 @@ Objective Parameters
Metric Parameters Metric Parameters
----------------- -----------------
- ``metric``, default = ``""``, type = multi-enum, aliases: ``metrics``, ``metric_types`` - ``metric`` :raw-html:`<a id="metric" title="Permalink to this parameter" href="#metric">&#x1F517;&#xFE0E;</a>`, default = ``""``, type = multi-enum, aliases: ``metrics``, ``metric_types``
- metric(s) to be evaluated on the evaluation sets **in addition** to what is provided in the training arguments - metric(s) to be evaluated on the evaluation sets **in addition** to what is provided in the training arguments
...@@ -774,15 +777,15 @@ Metric Parameters ...@@ -774,15 +777,15 @@ Metric Parameters
- support multiple metrics, separated by ``,`` - support multiple metrics, separated by ``,``
- ``metric_freq``, default = ``1``, type = int, aliases: ``output_freq``, constraints: ``metric_freq > 0`` - ``metric_freq`` :raw-html:`<a id="metric_freq" title="Permalink to this parameter" href="#metric_freq">&#x1F517;&#xFE0E;</a>`, default = ``1``, type = int, aliases: ``output_freq``, constraints: ``metric_freq > 0``
- frequency for metric output - frequency for metric output
- ``is_provide_training_metric``, default = ``false``, type = bool, aliases: ``training_metric``, ``is_training_metric``, ``train_metric`` - ``is_provide_training_metric`` :raw-html:`<a id="is_provide_training_metric" title="Permalink to this parameter" href="#is_provide_training_metric">&#x1F517;&#xFE0E;</a>`, default = ``false``, type = bool, aliases: ``training_metric``, ``is_training_metric``, ``train_metric``
- set this to ``true`` to output metric result over training dataset - set this to ``true`` to output metric result over training dataset
- ``eval_at``, default = ``1,2,3,4,5``, type = multi-int, aliases: ``ndcg_eval_at``, ``ndcg_at`` - ``eval_at`` :raw-html:`<a id="eval_at" title="Permalink to this parameter" href="#eval_at">&#x1F517;&#xFE0E;</a>`, default = ``1,2,3,4,5``, type = multi-int, aliases: ``ndcg_eval_at``, ``ndcg_at``
- used only with ``ndcg`` and ``map`` metrics - used only with ``ndcg`` and ``map`` metrics
...@@ -791,48 +794,48 @@ Metric Parameters ...@@ -791,48 +794,48 @@ Metric Parameters
Network Parameters Network Parameters
------------------ ------------------
- ``num_machines``, default = ``1``, type = int, aliases: ``num_machine``, constraints: ``num_machines > 0`` - ``num_machines`` :raw-html:`<a id="num_machines" title="Permalink to this parameter" href="#num_machines">&#x1F517;&#xFE0E;</a>`, default = ``1``, type = int, aliases: ``num_machine``, constraints: ``num_machines > 0``
- the number of machines for parallel learning application - the number of machines for parallel learning application
- this parameter is needed to be set in both **socket** and **mpi** versions - this parameter is needed to be set in both **socket** and **mpi** versions
- ``local_listen_port``, default = ``12400``, type = int, aliases: ``local_port``, ``port``, constraints: ``local_listen_port > 0`` - ``local_listen_port`` :raw-html:`<a id="local_listen_port" title="Permalink to this parameter" href="#local_listen_port">&#x1F517;&#xFE0E;</a>`, default = ``12400``, type = int, aliases: ``local_port``, ``port``, constraints: ``local_listen_port > 0``
- TCP listen port for local machines - TCP listen port for local machines
- **Note**: don't forget to allow this port in firewall settings before training - **Note**: don't forget to allow this port in firewall settings before training
- ``time_out``, default = ``120``, type = int, constraints: ``time_out > 0`` - ``time_out`` :raw-html:`<a id="time_out" title="Permalink to this parameter" href="#time_out">&#x1F517;&#xFE0E;</a>`, default = ``120``, type = int, constraints: ``time_out > 0``
- socket time-out in minutes - socket time-out in minutes
- ``machine_list_filename``, default = ``""``, type = string, aliases: ``machine_list_file``, ``machine_list``, ``mlist`` - ``machine_list_filename`` :raw-html:`<a id="machine_list_filename" title="Permalink to this parameter" href="#machine_list_filename">&#x1F517;&#xFE0E;</a>`, default = ``""``, type = string, aliases: ``machine_list_file``, ``machine_list``, ``mlist``
- path of file that lists machines for this parallel learning application - path of file that lists machines for this parallel learning application
- each line contains one IP and one port for one machine. The format is ``ip port`` (space as a separator) - each line contains one IP and one port for one machine. The format is ``ip port`` (space as a separator)
- ``machines``, default = ``""``, type = string, aliases: ``workers``, ``nodes`` - ``machines`` :raw-html:`<a id="machines" title="Permalink to this parameter" href="#machines">&#x1F517;&#xFE0E;</a>`, default = ``""``, type = string, aliases: ``workers``, ``nodes``
- list of machines in the following format: ``ip1:port1,ip2:port2`` - list of machines in the following format: ``ip1:port1,ip2:port2``
GPU Parameters GPU Parameters
-------------- --------------
- ``gpu_platform_id``, default = ``-1``, type = int - ``gpu_platform_id`` :raw-html:`<a id="gpu_platform_id" title="Permalink to this parameter" href="#gpu_platform_id">&#x1F517;&#xFE0E;</a>`, default = ``-1``, type = int
- OpenCL platform ID. Usually each GPU vendor exposes one OpenCL platform - OpenCL platform ID. Usually each GPU vendor exposes one OpenCL platform
- ``-1`` means the system-wide default platform - ``-1`` means the system-wide default platform
- ``gpu_device_id``, default = ``-1``, type = int - ``gpu_device_id`` :raw-html:`<a id="gpu_device_id" title="Permalink to this parameter" href="#gpu_device_id">&#x1F517;&#xFE0E;</a>`, default = ``-1``, type = int
- OpenCL device ID in the specified platform. Each GPU in the selected platform has a unique device ID - OpenCL device ID in the specified platform. Each GPU in the selected platform has a unique device ID
- ``-1`` means the default device in the selected platform - ``-1`` means the default device in the selected platform
- ``gpu_use_dp``, default = ``false``, type = bool - ``gpu_use_dp`` :raw-html:`<a id="gpu_use_dp" title="Permalink to this parameter" href="#gpu_use_dp">&#x1F517;&#xFE0E;</a>`, default = ``false``, type = bool
- set this to ``true`` to use double precision math on GPU (by default single precision is used) - set this to ``true`` to use double precision math on GPU (by default single precision is used)
...@@ -855,9 +858,12 @@ LightGBM supports continued training with initial scores. It uses an additional ...@@ -855,9 +858,12 @@ LightGBM supports continued training with initial scores. It uses an additional
It means the initial score of the first data row is ``0.5``, second is ``-0.1``, and so on. It means the initial score of the first data row is ``0.5``, second is ``-0.1``, and so on.
The initial score file corresponds with data file line by line, and has per score per line. The initial score file corresponds with data file line by line, and has per score per line.
And if the name of data file is ``train.txt``, the initial score file should be named as ``train.txt.init`` and in the same folder as the data file. And if the name of data file is ``train.txt``, the initial score file should be named as ``train.txt.init`` and in the same folder as the data file.
In this case LightGBM will auto load initial score file if it exists. In this case LightGBM will auto load initial score file if it exists.
Otherwise, you should specify the path to the custom named file with initial scores by the ``initscore_filename`` `parameter <#initscore_filename>`__.
Weight Data Weight Data
~~~~~~~~~~~ ~~~~~~~~~~~
...@@ -872,10 +878,11 @@ LightGBM supports weighted training. It uses an additional file to store weight ...@@ -872,10 +878,11 @@ LightGBM supports weighted training. It uses an additional file to store weight
It means the weight of the first data row is ``1.0``, second is ``0.5``, and so on. It means the weight of the first data row is ``1.0``, second is ``0.5``, and so on.
The weight file corresponds with data file line by line, and has per weight per line. The weight file corresponds with data file line by line, and has per weight per line.
And if the name of data file is ``train.txt``, the weight file should be named as ``train.txt.weight`` and placed in the same folder as the data file. And if the name of data file is ``train.txt``, the weight file should be named as ``train.txt.weight`` and placed in the same folder as the data file.
In this case LightGBM will load the weight file automatically if it exists. In this case LightGBM will load the weight file automatically if it exists.
Also, you can include weight column in your data file. Please refer to parameter ``weight`` in above. Also, you can include weight column in your data file. Please refer to the ``weight_column`` `parameter <#weight_column>`__ in above.
Query Data Query Data
~~~~~~~~~~ ~~~~~~~~~~
...@@ -897,6 +904,6 @@ It means first ``27`` lines samples belong to one query and next ``18`` lines be ...@@ -897,6 +904,6 @@ It means first ``27`` lines samples belong to one query and next ``18`` lines be
If the name of data file is ``train.txt``, the query file should be named as ``train.txt.query`` and placed in the same folder as the data file. If the name of data file is ``train.txt``, the query file should be named as ``train.txt.query`` and placed in the same folder as the data file.
In this case LightGBM will load the query file automatically if it exists. In this case LightGBM will load the query file automatically if it exists.
Also, you can include query/group id column in your data file. Please refer to parameter ``group`` in above. Also, you can include query/group id column in your data file. Please refer to the ``group_column`` `parameter <#group_column>`__ in above.
.. _Laurae++ Interactive Documentation: https://sites.google.com/view/lauraepp/parameters .. _Laurae++ Interactive Documentation: https://sites.google.com/view/lauraepp/parameters
...@@ -37,8 +37,8 @@ For the setting details, please refer to `Parameters <./Parameters.rst>`__. ...@@ -37,8 +37,8 @@ For the setting details, please refer to `Parameters <./Parameters.rst>`__.
Weight and Query/Group Data Weight and Query/Group Data
~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~
LightGBM also supports weighted training, it needs an additional `weight data <./Parameters.rst#io-parameters>`__. LightGBM also supports weighted training, it needs an additional `weight data <./Parameters.rst#weight-data>`__.
And it needs an additional `query data <./Parameters.rst#io-parameters>`_ for ranking task. And it needs an additional `query data <./Parameters.rst#query-data>`_ for ranking task.
Also, weight and query data could be specified as columns in training data in the same manner as label. Also, weight and query data could be specified as columns in training data in the same manner as label.
......
...@@ -147,7 +147,7 @@ def GenParameterDescription(sections, descriptions, params_rst): ...@@ -147,7 +147,7 @@ def GenParameterDescription(sections, descriptions, params_rst):
checks_str = ', constraints: ``{0} {1} {2}``'.format(name, sign, number) checks_str = ', constraints: ``{0} {1} {2}``'.format(name, sign, number)
else: else:
checks_str = '' checks_str = ''
main_desc = '- ``{0}``, default = ``{1}``, type = {2}{3}{4}{5}'.format(name, default, param_type, options_str, aliases_str, checks_str) main_desc = '- ``{0}`` :raw-html:`<a id="{0}" title="Permalink to this parameter" href="#{0}">&#x1F517;&#xFE0E;</a>`, default = ``{1}``, type = {2}{3}{4}{5}'.format(name, default, param_type, options_str, aliases_str, checks_str)
params_to_write.append(main_desc) params_to_write.append(main_desc)
params_to_write.extend([' ' * 3 * int(desc[0][-1]) + '- ' + desc[1] for desc in param_desc['desc']]) params_to_write.extend([' ' * 3 * int(desc[0][-1]) + '- ' + desc[1] for desc in param_desc['desc']])
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment