, td.getInputname().getName()
,toCluster.getSize()
,new Graph(toCluster.getNodes()).countTransitions()
));
Search gs = null;
if(td.getSearchType().equals("GA")){
gs = new GeneticAlgorithmSearch();
}else if(td.getSearchType().equals("RMHC")){
gs = new RandomMutationHillClimbingSearch();
}else{
throw new RuntimeException(String.format("Chosen search type %s is not a valid option", td.getSearchType()));
}
gs.setPopulationSize(td.getPopsize());
gs.setChromosomeSize(td.getChromesize());
gs.setGenerations(td.getNumgens());
gs.setFitnessFunction(fitnessFunction);
gs.setInput(toCluster);
gs.setGeneType(td.getGeneType());
gs.setExperimentName(td.getExperimentName());
gs.setFitnessBudget(td.getFitnessBudget());
SearchResult sr = null;
gs.setProgressStatus(monitor);
gs.setName(td.getInputname().toString());
sr = gs.start();
td.setResult(sr);
try {