Unverified Commit c8e0995b authored by Qiwei Ye's avatar Qiwei Ye Committed by GitHub
Browse files

[docs] Quick fix for better understanding for forced split logic (#1784)

* quick fix for better understanding

* update document for forced split

* typo fix

* made NOTE bold

* made Note bold
parent 402324f8
......@@ -362,6 +362,8 @@ Learning Control Parameters
- categorical splits are forced in a one-hot fashion, with ``left`` representing the split containing the feature value and ``right`` representing other values
- **Note**: the forced split logic will be ignored, if the split makes gain worse
- see `this file <https://github.com/Microsoft/LightGBM/tree/master/examples/binary_classification/forced_splits.json>`__ as an example
- ``refit_decay_rate`` :raw-html:`<a id="refit_decay_rate" title="Permalink to this parameter" href="#refit_decay_rate">&#x1F517;&#xFE0E;</a>`, default = ``0.9``, type = double, constraints: ``0.0 <= refit_decay_rate <= 1.0``
......
......@@ -365,6 +365,7 @@ public:
// desc = path to a ``.json`` file that specifies splits to force at the top of every decision tree before best-first learning commences
// desc = ``.json`` file can be arbitrarily nested, and each split contains ``feature``, ``threshold`` fields, as well as ``left`` and ``right`` fields representing subsplits
// desc = categorical splits are forced in a one-hot fashion, with ``left`` representing the split containing the feature value and ``right`` representing other values
// desc = **Note**: the forced split logic will be ignored, if the split makes gain worse
// desc = see `this file <https://github.com/Microsoft/LightGBM/tree/master/examples/binary_classification/forced_splits.json>`__ as an example
std::string forcedsplits_filename = "";
......
......@@ -336,7 +336,7 @@ public:
// gain with split is worse than without split
if (std::isnan(current_gain) || current_gain <= min_gain_shift) {
output->gain = kMinScore;
Log::Warning("Gain with forced split worse than without split");
Log::Warning("'Forced Split' will be ignored since the gain getting worse. ");
return;
};
......@@ -393,7 +393,7 @@ public:
meta_->config->max_delta_step);
if (std::isnan(current_gain) || current_gain <= min_gain_shift) {
output->gain = kMinScore;
Log::Warning("Gain with forced split worse than without split");
Log::Warning("'Forced Split' will be ignored since the gain getting worse. ");
return;
}
......
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