dotnet / dotnet/machinelearning

LightGbm Fit Error

Open
#6,862 1 comment 0 reactions 0 assignees View on GitHub
area-Trees untriaged
Dominant language
C#
Stars
9.4k
Forks
2k
Avg merge
2d 20h
Merged PRs (30d)
11

Description

**System Information (please complete the following information):**
- OS & Version: win10
- .NET Version: 7
Microsoft.ML,3.0.0-preview.23504.1
Microsoft.ML.TimeSeries,3.0.0-preview.23504.1
Microsoft.Data.Analysis,0.21.0-preview.23424.1
Microsoft.ML.AutoML,0.21.0-preview.23504.1
Microsoft.ML.OneDal,0.21.0-preview.23504.1

**Describe the bug**
Running automl regression with only lightgbm, refitting best pipeline:
```
finalmodel = regression_result.Estimator.Fit(idataview);
```
got error

```
Error: System.AggregateException: One or more errors occurred. (Index was outside the bounds of the array.)
---> System.IndexOutOfRangeException: Index was outside the bounds of the array.
at Microsoft.ML.Trainers.LightGbm.LightGbmTrainerBase`4.CopyToCsr(IChannel ch, FloatLabelCursor cursor, Int32[] indices, Single[] features, CategoricalMetaData catMetaData, Random rand, Int32& numElem)
at Microsoft.ML.Trainers.LightGbm.LightGbmTrainerBase`4.LoadDataset(IChannel ch, Factory factory, Dataset dataset, Int32 numRow, Int32 batchSize, CategoricalMetaData catMetaData)
at Microsoft.ML.Trainers.LightGbm.LightGbmTrainerBase`4.LoadTrainingData(IChannel ch, RoleMappedData trainData, CategoricalMetaData& catMetaData)
at Microsoft.ML.Trainers.LightGbm.LightGbmTrainerBase`4.TrainModelCore(TrainContext context)
at Microsoft.ML.Trainers.TrainerEstimatorBase`2.TrainTransformer(IDataView trainSet, IDataView validationSet, IPredictor initPredictor)
at Microsoft.ML.Data.EstimatorChain`1.Fit(IDataView input)

```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.