long long metric = tuner->getTime(problem);
if (metric == -1) {
metric = evaluate(problem, tuner);
- tuner->problems.push(problem);
- tuner->timetaken.put(problem, metric);
- if (tuner->getTime(problem) == -1)
++ if (tuner->getTime(problem) == -1){
+ tuner->problems.push(problem);
++ }
+ DEBUG("%u.Problem<%s>\tTuner<%p>\tMetric<%lld>\n", i, problem->problem,tuner, metric);
+ DEBUG("*****************************\n");
if (metric != -1)
tuner->setTime(problem, metric);
}
int tscore = 0;
if (scores.contains(t))
tscore = scores.get(t);
- if (score > tscore)
+ if (score < tscore)
break;
}
+ DEBUG("ranking[%u]=tuner<%p>(Score=%d)\n", j, tuner, score);
+ DEBUG("************************\n");
ranking.insertAt(j, tuner);
}
- model_print("tunerSize=%u\trankingSize=%u\ttunerVSize=%u\n", tuners.getSize(), ranking.getSize(), tunerV->getSize());
++ DEBUG("tunerSize=%u\trankingSize=%u\ttunerVSize=%u\n", tuners.getSize(), ranking.getSize(), tunerV->getSize());
for (uint i = tuners.getSize(); i < ranking.getSize(); i++) {
TunerRecord *tuner = ranking.get(i);
for (uint j = 0; j < tunerV->getSize(); j++) {