use of org.optaplanner.core.config.localsearch.decider.acceptor.LocalSearchAcceptorConfig in project kie-benchmarks by kiegroup.
the class VehicleRoutingBenchmark method getPhaseConfigList.
private List<PhaseConfig> getPhaseConfigList() {
ConstructionHeuristicPhaseConfig constructionHeuristicPhaseConfig = new ConstructionHeuristicPhaseConfig();
constructionHeuristicPhaseConfig.setConstructionHeuristicType(ConstructionHeuristicType.FIRST_FIT_DECREASING);
LocalSearchPhaseConfig localSearchPhaseConfig = new LocalSearchPhaseConfig();
SubChainChangeMoveSelectorConfig subChainChangeMoveSelectorConfig = new SubChainChangeMoveSelectorConfig();
subChainChangeMoveSelectorConfig.setSelectReversingMoveToo(true);
SubChainSwapMoveSelectorConfig subChainSwapMoveSelectorConfig = new SubChainSwapMoveSelectorConfig();
subChainSwapMoveSelectorConfig.setSelectReversingMoveToo(true);
List<MoveSelectorConfig> moveSelectorConfigList = Arrays.asList(new ChangeMoveSelectorConfig(), new SwapMoveSelectorConfig(), subChainChangeMoveSelectorConfig, subChainSwapMoveSelectorConfig);
UnionMoveSelectorConfig selectorConfig = new UnionMoveSelectorConfig(moveSelectorConfigList);
LocalSearchForagerConfig foragerConfig = new LocalSearchForagerConfig();
foragerConfig.setAcceptedCountLimit(FORAGER_CONFIG_ACCEPTED_COUNT_LIMIT);
localSearchPhaseConfig.setForagerConfig(foragerConfig);
localSearchPhaseConfig.setMoveSelectorConfig(selectorConfig);
localSearchPhaseConfig.setAcceptorConfig(new LocalSearchAcceptorConfig().withLateAcceptanceSize(ACCEPTOR_CONFIG_LATE_ACCEPTANCE_SIZE));
return Arrays.asList(constructionHeuristicPhaseConfig, localSearchPhaseConfig);
}
use of org.optaplanner.core.config.localsearch.decider.acceptor.LocalSearchAcceptorConfig in project kie-benchmarks by kiegroup.
the class AcceptorConfigurations method createHillClimbingAcceptor.
public static LocalSearchAcceptorConfig createHillClimbingAcceptor() {
LocalSearchAcceptorConfig localSearchAcceptorConfig = new LocalSearchAcceptorConfig();
localSearchAcceptorConfig.setAcceptorTypeList(Collections.singletonList(AcceptorType.HILL_CLIMBING));
return localSearchAcceptorConfig;
}
use of org.optaplanner.core.config.localsearch.decider.acceptor.LocalSearchAcceptorConfig in project kie-benchmarks by kiegroup.
the class AcceptorConfigurations method createLateAcceptanceAcceptor.
public static LocalSearchAcceptorConfig createLateAcceptanceAcceptor(Integer lateAcceptanceSize) {
LocalSearchAcceptorConfig localSearchAcceptorConfig = new LocalSearchAcceptorConfig();
localSearchAcceptorConfig.setLateAcceptanceSize(lateAcceptanceSize);
return localSearchAcceptorConfig;
}
use of org.optaplanner.core.config.localsearch.decider.acceptor.LocalSearchAcceptorConfig in project kie-benchmarks by kiegroup.
the class AcceptorConfigurations method createSimulatedAnnealingAcceptor.
public static LocalSearchAcceptorConfig createSimulatedAnnealingAcceptor(String startingTemperature) {
LocalSearchAcceptorConfig localSearchAcceptorConfig = new LocalSearchAcceptorConfig();
localSearchAcceptorConfig.setSimulatedAnnealingStartingTemperature(startingTemperature);
return localSearchAcceptorConfig;
}
use of org.optaplanner.core.config.localsearch.decider.acceptor.LocalSearchAcceptorConfig in project kie-benchmarks by kiegroup.
the class AcceptorConfigurations method createTabuSearchAcceptor.
public static LocalSearchAcceptorConfig createTabuSearchAcceptor(Double entityRatio) {
LocalSearchAcceptorConfig localSearchAcceptorConfig = new LocalSearchAcceptorConfig();
localSearchAcceptorConfig.setEntityTabuRatio(entityRatio);
return localSearchAcceptorConfig;
}
Aggregations