Пример #1
0
 protected override void Add(Floatarray v, int c)
 {
     if (_ds == null)
     {
         Global.Debugf("info", "allocating {0} buffer for classifier", PGet("cds"));
         _ds = ComponentCreator.MakeComponent<IExtDataset>(PGet("cds"));
     }
     _ds.Add(v, c);
 }
Пример #2
0
 public override void UpdateModel()
 {
     if (_ds == null)
         return;
     Console.WriteLine();
     Global.Debugf("info", "UpdateModel {0} samples, {1} features, {2} classes",
            _ds.nSamples(), _ds.nFeatures(), _ds.nClasses());
     Train(_ds);
     _ds = null;
 }