Skip to content

Commit 1fd8971

Browse files
authored
XML documentation for LightGBM binary classification. (#3397)
* XML documentation for LightGBM binary classification. * PR feedback.
1 parent 8376a17 commit 1fd8971

File tree

2 files changed

+25
-5
lines changed

2 files changed

+25
-5
lines changed

src/Microsoft.ML.LightGbm/LightGbmBinaryTrainer.cs

+21-1
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,27 @@ private static IPredictorProducing<float> Create(IHostEnvironment env, ModelLoad
8484
/// <summary>
8585
/// The <see cref="IEstimator{TTransformer}"/> for training a boosted decision tree binary classification model using LightGBM.
8686
/// </summary>
87-
/// <include file='doc.xml' path='doc/members/member[@name="LightGBM_remarks"]/*' />
87+
/// <remarks>
88+
/// <format type="text/markdown"><![CDATA[
89+
/// To create this trainer, use [LightGbm](xref:Microsoft.ML.LightGbmExtensions.LightGbm(Microsoft.ML.BinaryClassificationCatalog.BinaryClassificationTrainers,System.String,System.String,System.String,System.Nullable{System.Int32},System.Nullable{System.Int32},System.Nullable{System.Double},System.Int32)) or
90+
/// [LightGbm](xref:Microsoft.ML.LightGbmExtensions.LightGbm(Microsoft.ML.BinaryClassificationCatalog.BinaryClassificationTrainers,Microsoft.ML.Trainers.LightGbm.LightGbmBinaryTrainer.Options)).
91+
///
92+
/// [!include[io](~/../docs/samples/docs/api-reference/io-columns-binary-classification.md)]
93+
///
94+
/// ### Trainer Characteristics
95+
/// | | |
96+
/// | -- | -- |
97+
/// | Machine learning task | Binary classification |
98+
/// | Is normalization required? | No |
99+
/// | Is caching required? | No |
100+
/// | Required NuGet in addition to Microsoft.ML | Microsoft.ML.FastTree |
101+
///
102+
/// [!include[algorithm](~/../docs/samples/docs/api-reference/algo-details-lightgbm.md)]
103+
/// ]]>
104+
/// </format>
105+
/// </remarks>
106+
/// <seealso cref="LightGbmExtensions.LightGbm(BinaryClassificationCatalog.BinaryClassificationTrainers, string, string, string, int?, int?, double?, int)"/>
107+
/// <seealso cref="LightGbmExtensions.LightGbm(BinaryClassificationCatalog.BinaryClassificationTrainers, LightGbmBinaryTrainer.Options)"/>
88108
public sealed class LightGbmBinaryTrainer : LightGbmTrainerBase<LightGbmBinaryTrainer.Options, float,
89109
BinaryPredictionTransformer<CalibratedModelParametersBase<LightGbmBinaryModelParameters, PlattCalibrator>>,
90110
CalibratedModelParametersBase<LightGbmBinaryModelParameters, PlattCalibrator>>

src/Microsoft.ML.LightGbm/LightGbmCatalog.cs

+4-4
Original file line numberDiff line numberDiff line change
@@ -66,11 +66,11 @@ public static LightGbmRegressionTrainer LightGbm(this RegressionCatalog.Regressi
6666
}
6767

6868
/// <summary>
69-
/// Predict a target using a gradient boosting decision tree binary classification model trained with the <see cref="LightGbmBinaryTrainer"/>.
69+
/// Create <see cref="LightGbmBinaryTrainer"/>, which predicts a target using a gradient boosting decision tree binary classification.
7070
/// </summary>
7171
/// <param name="catalog">The <see cref="BinaryClassificationCatalog"/>.</param>
72-
/// <param name="labelColumnName">The name of the label column.</param>
73-
/// <param name="featureColumnName">The name of the feature column.</param>
72+
/// <param name="labelColumnName">The name of the label column. The column data must be <see cref="System.Boolean"/>.</param>
73+
/// <param name="featureColumnName">The name of the feature column. The column data must be a known-sized vector of <see cref="System.Single"/>.</param>
7474
/// <param name="exampleWeightColumnName">The name of the example weight column (optional).</param>
7575
/// <param name="numberOfLeaves">The maximum number of leaves in one tree.</param>
7676
/// <param name="minimumExampleCountPerLeaf">The minimal number of data points required to form a new tree leaf.</param>
@@ -98,7 +98,7 @@ public static LightGbmBinaryTrainer LightGbm(this BinaryClassificationCatalog.Bi
9898
}
9999

100100
/// <summary>
101-
/// Predict a target using a gradient boosting decision tree binary classification model trained with the <see cref="LightGbmBinaryTrainer"/> and advanced options.
101+
/// Create <see cref="LightGbmBinaryTrainer"/> with advanced options, which predicts a target using a gradient boosting decision tree binary classification.
102102
/// </summary>
103103
/// <param name="catalog">The <see cref="BinaryClassificationCatalog"/>.</param>
104104
/// <param name="options">Trainer options.</param>

0 commit comments

Comments
 (0)