2 writes to _host
Microsoft.ML.Recommender (2)
MatrixFactorizationTrainer.cs (2)
348_host = env.Register(LoadNameValue); 397_host = env.Register(LoadNameValue);
20 references to _host
Microsoft.ML.Recommender (20)
MatrixFactorizationTrainer.cs (20)
351_host.CheckValue(options, nameof(options)); 352_host.CheckUserArg(options.ApproximationRank > 0, nameof(options.ApproximationRank), posError); 353_host.CheckUserArg(!options.NumberOfThreads.HasValue || options.NumberOfThreads > 0, nameof(options.NumberOfThreads), posError); 354_host.CheckUserArg(options.NumberOfIterations > 0, nameof(options.NumberOfIterations), posError); 355_host.CheckUserArg(options.Lambda > 0, nameof(options.Lambda), posError); 356_host.CheckUserArg(options.LearningRate > 0, nameof(options.LearningRate), posError); 357_host.CheckUserArg(options.Alpha > 0, nameof(options.Alpha), posError); 425_host.CheckValue(context, nameof(context)); 426using (var ch = _host.Start("Training")) 437_host.AssertValue(ch); 468int colCount = matrixColumnIndexColInfo.Type.GetKeyCountAsInt32(_host); 469int rowCount = matrixRowIndexColInfo.Type.GetKeyCountAsInt32(_host); 487predictor = new MatrixFactorizationModelParameters(_host, buffer, (KeyDataViewType)matrixColumnIndexColInfo.Type, (KeyDataViewType)matrixRowIndexColInfo.Type); 505predictor = new MatrixFactorizationModelParameters(_host, buffer, (KeyDataViewType)matrixColumnIndexColInfo.Type, (KeyDataViewType)matrixRowIndexColInfo.Type); 516return new SafeTrainingAndModelBuffer(_host, _fun, _k, _threads, 2 * _threads + 1, 536using (var ch = _host.Start("Training")) 541return new MatrixFactorizationPredictionTransformer(_host, model, trainData.Schema, MatrixColumnIndexName, MatrixRowIndexName); 556_host.CheckValue(inputSchema, nameof(inputSchema)); 561throw _host.ExceptSchemaMismatch(nameof(col), columnRole, cachedColumn.Name); 564throw _host.ExceptSchemaMismatch(nameof(inputSchema), columnRole, cachedColumn.Name,