Commit 01f3a880 authored by René Schöne's avatar René Schöne
Browse files

Small modification to reduce output volume and test time.

parent 2ecd7c2b
......@@ -47,6 +47,16 @@ public class ACOSolver implements BenchmarkableSolver {
reset();
}
public ACOSolver setPopulation_size(int population_size) {
this.population_size = population_size;
return this;
}
public ACOSolver setIteration_size(int iteration_size) {
this.iteration_size = iteration_size;
return this;
}
public Assignment ACOCreateSoftwareAssignment(Request request, Component component, boolean topLevel, int i) {
Assignment assignment = new Assignment();
assignment.setRequest(request);
......@@ -110,7 +120,7 @@ public class ACOSolver implements BenchmarkableSolver {
for (int pop = 0; pop < population_size; pop++) {
System.out.println("pop: " + pop);
logger.trace("pop: {}", pop);
Solution currentSolution = new Solution();
currentSolution.setModel(model);
de.tudresden.inf.st.mquat.jastadd.model.List<Request> requests = model.getRequests();
......@@ -174,7 +184,7 @@ public class ACOSolver implements BenchmarkableSolver {
}
if(isHardwareValid == true){
numSoftwareSolutions++;
System.out.println("valid:" + numSoftwareSolutions);
logger.trace("valid: {}", numSoftwareSolutions);
Solution clone = currentSolution.deepCopy();
currentSolutions.add(clone);
currentPossibleResources.add(possibleResources);
......
......@@ -11,6 +11,6 @@ import de.tudresden.inf.st.mquat.solving.Solver;
public class ACOHandwrittenTest extends HandwrittenTestSuite {
@Override
protected Solver getSolver() {
return new ACOSolver();
return new ACOSolver().setPopulation_size(100);
}
}
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment