Program: 32085
Project: 32085
Buggy source:
public ScoreObject score(MLDataPair pair,Map<String,String> rawDataMap){
  if (pair == null) {
    return null;
  }
  List<Integer> scores=new ArrayList<Integer>();
  for (  BasicML model : models) {
    if (model instanceof BasicNetwork) {
      BasicNetwork network=(BasicNetwork)model;
      if (network.getInputCount() != pair.getInput().size()) {
        log.error("String_Node_Str" + network.getInputCount() + "String_Node_Str"+ pair.getInput().size());
        continue;
      }
      MLData score=network.compute(pair.getInput());
      if (modelConfig.isBinaryClassification()) {
        scores.add(toScore(score.getData(0)));
      }
 else {
        double[] outputs=score.getData();
        for (        double d : outputs) {
          scores.add(toScore(d));
        }
      }
    }
 else     if (model instanceof SVM) {
      SVM svm=(SVM)model;
      if (svm.getInputCount() != pair.getInput().size()) {
        log.error("String_Node_Str" + svm.getInputCount() + "String_Node_Str"+ pair.getInput().size());
        continue;
      }
      MLData score=svm.compute(pair.getInput());
      scores.add(toScore(score.getData(0)));
    }
 else     if (model instanceof LR) {
      LR lr=(LR)model;
      if (lr.getInputCount() != pair.getInput().size()) {
        log.error("String_Node_Str" + lr.getInputCount() + "String_Node_Str"+ pair.getInput().size());
        continue;
      }
      MLData score=lr.compute(pair.getInput());
      scores.add(toScore(score.getData(0)));
    }
 else {
      throw new RuntimeException("String_Node_Str");
    }
  }
  Integer tag=(int)pair.getIdeal().getData(0);
  if (scores.size() == 0) {
    log.error("String_Node_Str");
    return null;
  }
  return new ScoreObject(scores,tag);
}

Fixed version (ground truth):
public ScoreObject score(MLDataPair pair,Map<String,String> rawDataMap){
  if (pair == null) {
    return null;
  }
  List<Integer> scores=new ArrayList<Integer>();
  for (  BasicML model : models) {
    if (model instanceof BasicNetwork) {
      BasicNetwork network=(BasicNetwork)model;
      if (network.getInputCount() != pair.getInput().size()) {
        log.error("String_Node_Str" + network.getInputCount() + "String_Node_Str"+ pair.getInput().size());
        continue;
      }
      MLData score=network.compute(pair.getInput());
      if (modelConfig != null && modelConfig.isBinaryClassification()) {
        scores.add(toScore(score.getData(0)));
      }
 else {
        double[] outputs=score.getData();
        for (        double d : outputs) {
          scores.add(toScore(d));
        }
      }
    }
 else     if (model instanceof SVM) {
      SVM svm=(SVM)model;
      if (svm.getInputCount() != pair.getInput().size()) {
        log.error("String_Node_Str" + svm.getInputCount() + "String_Node_Str"+ pair.getInput().size());
        continue;
      }
      MLData score=svm.compute(pair.getInput());
      scores.add(toScore(score.getData(0)));
    }
 else     if (model instanceof LR) {
      LR lr=(LR)model;
      if (lr.getInputCount() != pair.getInput().size()) {
        log.error("String_Node_Str" + lr.getInputCount() + "String_Node_Str"+ pair.getInput().size());
        continue;
      }
      MLData score=lr.compute(pair.getInput());
      scores.add(toScore(score.getData(0)));
    }
 else {
      throw new RuntimeException("String_Node_Str");
    }
  }
  Integer tag=(int)pair.getIdeal().getData(0);
  if (scores.size() == 0) {
    log.error("String_Node_Str");
    return null;
  }
  return new ScoreObject(scores,tag);
}