I'm evaluating ML.NET Model Builder (Preview) 16.1.0.2027905. When I go to train, the Builder lets me specify "Time to train (seconds)" (See Picture):
However, when I get to Step#6 and generate the code, I can't seem to find where the "Time to train" is specified...
The ML.NET Builder creates this function for me automatically in the ModelBuilder.cs file:
public static ITransformer TrainModel(MLContext mlContext, IDataView trainingDataView, IEstimator<ITransformer> trainingPipeline)
{
Console.WriteLine("=============== Training model ===============");
ITransformer model = trainingPipeline.Fit(trainingDataView);
Console.WriteLine("=============== End of training process ===============");
return model;
}
but I looked in the debugger at the mlContext, trainingDataView, trainingPipeline objects and didn't immediately see where I can specify time to train. Also, I did a global text search for 3600 (which is the time I trained for) and I didn't find any interesting code that way.
Is there some easy way in ML.NET to specify "Time to train" in seconds?
I'm asking this question because I want to call ModelBuilder.TrainModel manually with a user specified training interval. I don't want to always be required to use the ML.NET Builder GUI to retrain my model.