public Mx trainProbs(final Mx codingMatrix, final Func[] binClassifiers) {
   final Mx result = new VecBasedMx(codingMatrix.rows(), codingMatrix.columns());
   for (int l = 0; l < result.columns(); l++) {
     System.out.println("Optimize column " + l);
     final FuncC1 columnTargetFunction = new ColumnTargetFunction(binClassifiers[l]);
     final Vec muColumn = optimizeColumn(columnTargetFunction, codingMatrix.col(l));
     VecTools.assign(result.col(l), muColumn);
   }
   return result;
 }
Example #2
0
 public Vec gradientTo(Vec x, Vec to) {
   final Vec trans = gradient(x);
   VecTools.assign(to, trans);
   return to;
 }