public String[] makeSvmLabelMap() {
    String[] labelMap = new String[numClasses()];
    if (numClasses() > 2) {
      for (int i = 0; i < labelMap.length; i++) {
        labelMap[i] = String.valueOf((i + 1));
      }
    } else {
      labelMap = new String[]{"+1", "-1"};
    }
    return labelMap;
  }
public String [ ] makeSvmLabelMap ( ) { String [ ] labelMap = new String [ numClasses ( ) ] ; if ( numClasses ( ) > 2 ) { for ( int i = 0 ; i < labelMap . length ; i ++ ) { labelMap [ i ] = String . valueOf ( ( i + 1 ) ) ; } } else { labelMap = new String [ ] { "+1" , "-1" } ; } return labelMap ; }
Maps our labels to labels that are compatible with svm_light
@return array of strings