1 write to Regression
Microsoft.ML.Data (1)
MLContext.cs (1)
145
Regression
= new RegressionCatalog(_env);
196 references to Regression
Microsoft.ML.AutoML (22)
API\RegressionExperiment.cs (2)
400
var metrics = _context.
Regression
.CrossValidate(datasetManager.Dataset, pipeline, fold, metricManager.LabelColumn);
430
var metrics = _context.
Regression
.Evaluate(eval, metricManager.LabelColumn, scoreColumnName: metricManager.ScoreColumn);
AutoMLExperiment\IMetricManager.cs (1)
130
var metric = context.
Regression
.Evaluate(eval, LabelColumn, ScoreColumn);
Experiment\MetricsAgents\RegressionMetricsAgent.cs (1)
66
return _mlContext.
Regression
.Evaluate(data, labelColumn);
SweepableEstimator\Estimators\FastForest.cs (1)
41
return context.
Regression
.Trainers.FastForest(option);
SweepableEstimator\Estimators\FastTree.cs (2)
51
return context.
Regression
.Trainers.FastTree(option);
74
return context.
Regression
.Trainers.FastTreeTweedie(option);
SweepableEstimator\Estimators\Lbfgs.cs (1)
41
return context.
Regression
.Trainers.LbfgsPoissonRegression(option);
SweepableEstimator\Estimators\LightGbm.cs (1)
89
return context.
Regression
.Trainers.LightGbm(option);
SweepableEstimator\Estimators\Sdca.cs (1)
23
return context.
Regression
.Trainers.Sdca(option);
SweepableEstimator\Estimators\SentenceSimilarity.cs (1)
17
return context.
Regression
.Trainers.SentenceSimilarity(
Sweepers\SmacSweeper.cs (1)
129
var trainer = _context.
Regression
.Trainers.FastForest(new FastForestRegressionTrainer.Options()
TrainerExtensions\RegressionTrainerExtensions.cs (8)
27
return mlContext.
Regression
.Trainers.FastForest(options);
49
return mlContext.
Regression
.Trainers.FastTree(options);
71
return mlContext.
Regression
.Trainers.FastTreeTweedie(options);
92
return mlContext.
Regression
.Trainers.LightGbm(options);
113
return mlContext.
Regression
.Trainers.OnlineGradientDescent(options);
135
return mlContext.
Regression
.Trainers.Ols(options);
157
return mlContext.
Regression
.Trainers.LbfgsPoissonRegression(options);
178
return mlContext.
Regression
.Trainers.Sdca(options);
Tuner\SmacTuner.cs (2)
141
var trainer = _context.
Regression
.Trainers.FastForest(new FastForestRegressionTrainer.Options()
151
var eval = _context.
Regression
.Evaluate(test);
Microsoft.ML.AutoML.Samples (1)
AutoFit\RegressionExperiment.cs (1)
40
RegressionMetrics testMetrics = mlContext.
Regression
.Evaluate(testDataViewWithBestScore, labelColumnName: LabelColumnName);
Microsoft.ML.AutoML.Tests (1)
Utils\TaskAgnosticAutoFit.cs (1)
153
var regressionMetrics = _context.
Regression
.Evaluate(result.ScoredTestData, labelColumnName: label);
Microsoft.ML.Fairlearn (2)
Metrics\FairlearnMetricCatalog.cs (2)
229
RegressionMetrics metrics = _context.
Regression
.Evaluate(data, _labelColumn, _scoreColumn);
256
RegressionMetrics metrics = _context.
Regression
.Evaluate(_eval, _labelColumn);
Microsoft.ML.IntegrationTests (30)
Debugging.cs (2)
109
.Append(mlContext.
Regression
.Trainers.Sdca(
176
.Append(mlContext.
Regression
.Trainers.Sdca(
Evaluation.cs (2)
271
.Append(mlContext.
Regression
.Trainers.FastForest(new FastForestRegressionTrainer.Options { NumberOfThreads = 1 }));
278
var metrics = mlContext.
Regression
.Evaluate(scoredData);
Explainability.cs (9)
39
.Append(mlContext.
Regression
.Trainers.FastTree());
72
var permutationMetrics = mlContext.
Regression
.PermutationFeatureImportance(linearPredictor, transformedData);
97
.Append(mlContext.
Regression
.Trainers.Sdca());
121
.Append(mlContext.
Regression
.Trainers.FastTree());
148
.Append(mlContext.
Regression
.Trainers.FastForest());
175
.Append(mlContext.
Regression
.Trainers.Sdca());
212
.Append(mlContext.
Regression
.Trainers.FastTree());
249
.Append(mlContext.
Regression
.Trainers.FastForest());
287
.Append(mlContext.
Regression
.Trainers.Gam(numberOfIterations: 2));
IntrospectiveTraining.cs (3)
39
.Append(mlContext.
Regression
.Trainers.FastForest(
144
.Append(mlContext.
Regression
.Trainers.Gam(
293
.Append(mlContext.
Regression
.Trainers.FastForest(numberOfLeaves: 5, numberOfTrees: 3));
ModelFiles.cs (2)
49
.Append(mlContext.
Regression
.Trainers.FastTree(
96
.Append(mlContext.
Regression
.Trainers.FastTree(
ONNX.cs (2)
43
.Append(mlContext.
Regression
.Trainers.FastTree(
145
.Append(mlContext.
Regression
.Trainers.Sdca(
Training.cs (2)
321
var trainer = mlContext.
Regression
.Trainers.OnlineGradientDescent(
365
var trainer = mlContext.
Regression
.Trainers.LbfgsPoissonRegression(
Validation.cs (8)
42
.Append(mlContext.
Regression
.Trainers.Ols());
45
var cvResult = mlContext.
Regression
.CrossValidate(data, pipeline, numberOfFolds: 5);
121
var trainedModel = mlContext.
Regression
.Trainers.FastTree(new FastTreeRegressionTrainer.Options
136
var trainMetrics = mlContext.
Regression
.Evaluate(scoredTrainData);
137
var validMetrics = mlContext.
Regression
.Evaluate(scoredValidData);
155
.Append(mlContext.
Regression
.Trainers.OnlineGradientDescent());
161
var evalResultOneRow = mlContext.
Regression
.Evaluate(scoredDataOneRow);
167
var evalResultZeroRows = mlContext.
Regression
.Evaluate(scoredDataZeroRows);
Microsoft.ML.Predictor.Tests (2)
TestIniModels.cs (2)
531
.Append(mlContext.
Regression
.Trainers.Gam());
544
var results = mlContext.
Regression
.Evaluate(data);
Microsoft.ML.Samples (51)
Dynamic\Trainers\Recommendation\MatrixFactorization.cs (1)
64
var metrics = mlContext.
Regression
.Evaluate(transformedData,
Dynamic\Trainers\Recommendation\MatrixFactorizationWithOptions.cs (1)
88
var metrics = mlContext.
Regression
.Evaluate(transformedData,
Dynamic\Trainers\Regression\FastForest.cs (2)
30
var pipeline = mlContext.
Regression
.Trainers.FastForest(
62
var metrics = mlContext.
Regression
.Evaluate(transformedTestData);
Dynamic\Trainers\Regression\FastForestWithOptions.cs (2)
45
mlContext.
Regression
.Trainers.FastForest(options);
75
var metrics = mlContext.
Regression
.Evaluate(transformedTestData);
Dynamic\Trainers\Regression\FastTree.cs (2)
30
var pipeline = mlContext.
Regression
.Trainers.FastTree(
62
var metrics = mlContext.
Regression
.Evaluate(transformedTestData);
Dynamic\Trainers\Regression\FastTreeTweedie.cs (2)
30
var pipeline = mlContext.
Regression
.Trainers.FastTreeTweedie(
62
var metrics = mlContext.
Regression
.Evaluate(transformedTestData);
Dynamic\Trainers\Regression\FastTreeTweedieWithOptions.cs (2)
47
mlContext.
Regression
.Trainers.FastTreeTweedie(options);
77
var metrics = mlContext.
Regression
.Evaluate(transformedTestData);
Dynamic\Trainers\Regression\FastTreeWithOptions.cs (2)
48
mlContext.
Regression
.Trainers.FastTree(options);
78
var metrics = mlContext.
Regression
.Evaluate(transformedTestData);
Dynamic\Trainers\Regression\Gam.cs (2)
30
var pipeline = mlContext.
Regression
.Trainers.Gam(
62
var metrics = mlContext.
Regression
.Evaluate(transformedTestData);
Dynamic\Trainers\Regression\GamWithOptions.cs (2)
43
mlContext.
Regression
.Trainers.Gam(options);
73
var metrics = mlContext.
Regression
.Evaluate(transformedTestData);
Dynamic\Trainers\Regression\LbfgsPoissonRegression.cs (2)
27
var pipeline = mlContext.
Regression
.Trainers.
60
var metrics = mlContext.
Regression
.Evaluate(transformedTestData);
Dynamic\Trainers\Regression\LbfgsPoissonRegressionWithOptions.cs (2)
44
mlContext.
Regression
.Trainers.LbfgsPoissonRegression(options);
74
var metrics = mlContext.
Regression
.Evaluate(transformedTestData);
Dynamic\Trainers\Regression\LightGbm.cs (2)
30
var pipeline = mlContext.
Regression
.Trainers.
63
var metrics = mlContext.
Regression
.Evaluate(transformedTestData);
Dynamic\Trainers\Regression\LightGbmAdvanced.cs (2)
41
.Append(mlContext.
Regression
.Trainers.LightGbm(
62
var metrics = mlContext.
Regression
.Evaluate(
Dynamic\Trainers\Regression\LightGbmWithOptions.cs (2)
52
mlContext.
Regression
.Trainers.LightGbm(options);
82
var metrics = mlContext.
Regression
.Evaluate(transformedTestData);
Dynamic\Trainers\Regression\LightGbmWithOptionsAdvanced.cs (2)
42
.Append(mlContext.
Regression
.Trainers.LightGbm(
71
var metrics = mlContext.
Regression
.Evaluate(
Dynamic\Trainers\Regression\OnlineGradientDescent.cs (2)
27
var pipeline = mlContext.
Regression
.Trainers.OnlineGradientDescent(
55
var metrics = mlContext.
Regression
.Evaluate(transformedTestData);
Dynamic\Trainers\Regression\OnlineGradientDescentWithOptions.cs (2)
44
mlContext.
Regression
.Trainers.OnlineGradientDescent(options);
70
var metrics = mlContext.
Regression
.Evaluate(transformedTestData);
Dynamic\Trainers\Regression\OrdinaryLeastSquares.cs (2)
27
var pipeline = mlContext.
Regression
.Trainers.Ols(
59
var metrics = mlContext.
Regression
.Evaluate(transformedTestData);
Dynamic\Trainers\Regression\OrdinaryLeastSquaresAdvanced.cs (2)
53
var pipeline = mlContext.
Regression
.Trainers.Ols();
64
var metrics = mlContext.
Regression
.Evaluate(dataWithPredictions);
Dynamic\Trainers\Regression\OrdinaryLeastSquaresWithOptions.cs (2)
41
mlContext.
Regression
.Trainers.Ols(options);
71
var metrics = mlContext.
Regression
.Evaluate(transformedTestData);
Dynamic\Trainers\Regression\OrdinaryLeastSquaresWithOptionsAdvanced.cs (2)
53
var pipeline = mlContext.
Regression
.Trainers.Ols(
68
var metrics = mlContext.
Regression
.Evaluate(dataWithPredictions);
Dynamic\Trainers\Regression\PermutationFeatureImportance.cs (2)
32
.Append(mlContext.
Regression
.Trainers.Ols());
45
var permutationMetrics = mlContext.
Regression
Dynamic\Trainers\Regression\PermutationFeatureImportanceLoadFromDisk.cs (2)
34
.Append(mlContext.
Regression
.Trainers.Ols());
52
var permutationMetrics = mlContext.
Regression
Dynamic\Trainers\Regression\Sdca.cs (2)
27
var pipeline = mlContext.
Regression
.Trainers.Sdca(
59
var metrics = mlContext.
Regression
.Evaluate(transformedTestData);
Dynamic\Trainers\Regression\SdcaWithOptions.cs (2)
45
mlContext.
Regression
.Trainers.Sdca(options);
75
var metrics = mlContext.
Regression
.Evaluate(transformedTestData);
Dynamic\Transforms\CalculateFeatureContribution.cs (1)
36
var linearTrainer = mlContext.
Regression
.Trainers.Ols();
Microsoft.ML.Samples.OneDal (6)
Program.cs (6)
111
var trainer = mlContext.
Regression
.Trainers.FastForest(options);
116
var trainingMetrics = mlContext.
Regression
.Evaluate(trainingPredictions, labelColumnName: labelName);
118
var testingMetrics = mlContext.
Regression
.Evaluate(testingPredictions, labelColumnName: labelName);
139
var trainer = mlContext.
Regression
.Trainers.Ols(options);
144
var trainingMetrics = mlContext.
Regression
.Evaluate(trainingPredictions, labelColumnName: labelName);
146
var testingMetrics = mlContext.
Regression
.Evaluate(testingPredictions, labelColumnName: labelName);
Microsoft.ML.Tests (79)
FeatureContributionTests.cs (11)
31
var model = ML.
Regression
.Trainers.Ols().Fit(data);
47
TestFeatureContribution(ML.
Regression
.Trainers.Ols(), GetSparseDataset(numberOfInstances: 100), "LeastSquaresRegression");
53
TestFeatureContribution(ML.
Regression
.Trainers.LightGbm(), GetSparseDataset(numberOfInstances: 100), "LightGbmRegression");
59
TestFeatureContribution(ML.
Regression
.Trainers.LightGbm(new LightGbmRegressionTrainer.Options() { UseCategoricalSplit = true }), GetOneHotEncodedData(numberOfInstances: 100), "LightGbmRegressionWithCategoricalSplit");
65
TestFeatureContribution(ML.
Regression
.Trainers.FastTree(), GetSparseDataset(numberOfInstances: 100), "FastTreeRegression");
71
TestFeatureContribution(ML.
Regression
.Trainers.FastForest(), GetSparseDataset(numberOfInstances: 100), "FastForestRegression");
77
TestFeatureContribution(ML.
Regression
.Trainers.FastTreeTweedie(), GetSparseDataset(numberOfInstances: 100), "FastTreeTweedieRegression");
83
TestFeatureContribution(ML.
Regression
.Trainers.Sdca(
90
TestFeatureContribution(ML.
Regression
.Trainers.OnlineGradientDescent(), GetSparseDataset(numberOfInstances: 100), "OnlineGradientDescentRegression");
96
TestFeatureContribution(ML.
Regression
.Trainers.LbfgsPoissonRegression(
103
TestFeatureContribution(ML.
Regression
.Trainers.Gam(), GetSparseDataset(numberOfInstances: 100), "GAMRegression");
OnnxConversionTest.cs (10)
79
.Append(mlContext.
Regression
.Trainers.Sdca(new SdcaRegressionTrainer.Options()
189
mlContext.
Regression
.Trainers.OnlineGradientDescent("Target","FeatureVector"),
190
mlContext.
Regression
.Trainers.FastForest("Target", "FeatureVector"),
191
mlContext.
Regression
.Trainers.FastTree("Target", "FeatureVector"),
192
mlContext.
Regression
.Trainers.FastTreeTweedie("Target", "FeatureVector"),
193
mlContext.
Regression
.Trainers.LbfgsPoissonRegression("Target", "FeatureVector"),
197
estimators.Add(mlContext.
Regression
.Trainers.Ols("Target", "FeatureVector"));
201
estimators.Add(mlContext.
Regression
.Trainers.LightGbm("Target", "FeatureVector"));
575
.Append(mlContext.
Regression
.Trainers.Sdca(new SdcaRegressionTrainer.Options()
606
.Append(mlContext.
Regression
.Trainers.LightGbm(labelColumnName: "Target", featureColumnName: "FeatureVector", numberOfIterations: 3, numberOfLeaves: 16, minimumExampleCountPerLeaf: 100));
PermutationFeatureImportanceTests.cs (20)
38
var model = ML.
Regression
.Trainers.OnlineGradientDescent().Fit(data);
55
pfi = ML.
Regression
.PermutationFeatureImportance(castedModel, data);
56
pfiDict = ml2.
Regression
.PermutationFeatureImportance(loadedModel, data);
64
pfi = ML.
Regression
.PermutationFeatureImportance(model, data);
65
pfiDict = ml2.
Regression
.PermutationFeatureImportance((ITransformer)model, data);
106
var model = ML.Transforms.CopyColumns("Label", "Label").Append(ML.
Regression
.Trainers.OnlineGradientDescent()).Fit(data);
129
pfi = ML.
Regression
.PermutationFeatureImportance(castedModel, data);
130
pfiDict = ml2.
Regression
.PermutationFeatureImportance(loadedModel, data);
138
pfi = ML.
Regression
.PermutationFeatureImportance(model.LastTransformer, data);
139
pfiDict = ml2.
Regression
.PermutationFeatureImportance(model, data);
180
var model = ML.
Regression
.Trainers.OnlineGradientDescent().Fit(data);
197
pfi = ML.
Regression
.PermutationFeatureImportance(castedModel, data, permutationCount: 20);
198
pfiDict = ml2.
Regression
.PermutationFeatureImportance(loadedModel, data, permutationCount: 20);
206
pfi = ML.
Regression
.PermutationFeatureImportance(model, data, permutationCount: 20);
207
pfiDict = ml2.
Regression
.PermutationFeatureImportance((ITransformer)model, data, permutationCount: 20);
268
var model = ML.
Regression
.Trainers.OnlineGradientDescent().Fit(data);
285
results = ML.
Regression
.PermutationFeatureImportance(castedModel, data);
286
pfiDict = ml2.
Regression
.PermutationFeatureImportance(loadedModel, data);
294
results = ML.
Regression
.PermutationFeatureImportance(model, data);
295
pfiDict = ml2.
Regression
.PermutationFeatureImportance((ITransformer)model, data);
Scenarios\Api\CookbookSamples\CookbookSamplesDynamicApi.cs (7)
181
.Append(mlContext.
Regression
.Trainers.Sdca(labelColumnName: "Target", featureColumnName: "FeatureVector"));
195
var metrics = mlContext.
Regression
.Evaluate(model.Transform(testData), labelColumnName: "Target");
353
.Append(context.
Regression
.Trainers.FastTree());
359
var featureImportance = context.
Regression
.PermutationFeatureImportance(model.LastTransformer, transformedData);
393
.Append(context.
Regression
.Trainers.Sdca());
428
.Append(context.
Regression
.Trainers.FastTree());
464
.Append(context.
Regression
.Trainers.FastTree(labelColumnName: "MedianHomeValue"));
Scenarios\RegressionTest.cs (2)
37
var trainer = context.
Regression
.Trainers.Sdca(labelColumnName: "Label", featureColumnName: "Features");
44
var metrics = context.
Regression
.Evaluate(predictions);
TrainerEstimators\LbfgsTests.cs (1)
50
var trainer = ML.
Regression
.Trainers.LbfgsPoissonRegression();
TrainerEstimators\OlsLinearRegressionTests.cs (2)
18
var trainer = ML.
Regression
.Trainers.Ols(new OlsTrainer.Options());
26
trainer = ML.
Regression
.Trainers.Ols(new OlsTrainer.Options() { CalculateStatistics = false });
TrainerEstimators\OnlineLinearTests.cs (1)
29
var ogdTrainer = ML.
Regression
.Trainers.OnlineGradientDescent();
TrainerEstimators\SdcaTests.cs (1)
39
var regressionTrainer = ML.
Regression
.Trainers.Sdca(
TrainerEstimators\TreeEnsembleFeaturizerTest.cs (16)
456
.Append(ML.
Regression
.Trainers.Sdca("Label", "CombinedFeatures"));
459
var metrics = ML.
Regression
.Evaluate(prediction);
494
.Append(ML.
Regression
.Trainers.Sdca("Label", "CombinedFeatures"));
497
var metrics = ML.
Regression
.Evaluate(prediction);
532
.Append(ML.
Regression
.Trainers.Sdca("Label", "CombinedFeatures"));
535
var metrics = ML.
Regression
.Evaluate(prediction);
570
.Append(ML.
Regression
.Trainers.Sdca("Label", "CombinedFeatures"));
573
var metrics = ML.
Regression
.Evaluate(prediction);
608
.Append(ML.
Regression
.Trainers.Sdca("Label", "CombinedFeatures"));
611
var metrics = ML.
Regression
.Evaluate(prediction);
628
var loadedMetrics = ML.
Regression
.Evaluate(loadedPrediction);
665
.Append(ML.
Regression
.Trainers.Sdca("Label", "CombinedFeatures"));
668
var metrics = ML.
Regression
.Evaluate(prediction);
687
var loadedMetrics = ML.
Regression
.Evaluate(loadedPrediction);
697
.Append(ML.
Regression
.Trainers.Sdca("Label", "CombinedFeatures"));
700
var secondMetrics = ML.
Regression
.Evaluate(secondPrediction);
TrainerEstimators\TreeEstimators.cs (8)
216
var trainer = ML.
Regression
.Trainers.FastTree(
234
var trainer = ML.
Regression
.Trainers.LightGbm(new LightGbmRegressionTrainer.Options
271
var trainer = ML.
Regression
.Trainers.FastTreeTweedie(
290
var trainer = ML.
Regression
.Trainers.FastForest(
909
var trainer = ML.
Regression
.Trainers.FastTree(
927
var trainer = ML.
Regression
.Trainers.FastForest(
945
var trainer = ML.
Regression
.Trainers.FastTreeTweedie(
966
var trainer = ML.
Regression
.Trainers.LightGbm(
Microsoft.ML.TorchSharp.Tests (2)
TextClassificationTests.cs (2)
387
var estimator = ML.
Regression
.Trainers.SentenceSimilarity(sentence1ColumnName: "Sentence", sentence2ColumnName: "Sentence2");
442
var estimator = ML.
Regression
.Trainers.SentenceSimilarity(options);