Package jsprit.analysis.toolbox

Examples of jsprit.analysis.toolbox.StopWatch


     * Get schrimpf with threshold accepting
     * Note that Priority.LOW is a way to priorize AlgorithmListeners
     */
    VehicleRoutingAlgorithm vra_withThreshold = new SchrimpfFactory().createAlgorithm(vrp);
    vra_withThreshold.getAlgorithmListeners().addListener(new AlgorithmSearchProgressChartListener("output/schrimpfThreshold_progress.png"), Priority.LOW);
    vra_withThreshold.getAlgorithmListeners().addListener(new StopWatch(), Priority.HIGH);
    /*
     * Get greedy schrimpf
     */
    VehicleRoutingAlgorithm vra_greedy = new GreedySchrimpfFactory().createAlgorithm(vrp);
    vra_greedy.getAlgorithmListeners().addListener(new AlgorithmSearchProgressChartListener("output/schrimpfGreedy_progress.png"), Priority.LOW);
    vra_greedy.getAlgorithmListeners().addListener(new StopWatch(), Priority.HIGH);

    /*
     * run both
     */
    vra_withThreshold.searchSolutions();
 
View Full Code Here


    /*
     * solve the problem
     */
    VehicleRoutingAlgorithm vra = VehicleRoutingAlgorithms.readAndCreateAlgorithm(vrp, "input/algorithmConfig.xml");
    vra.setMaxIterations(10000);
        vra.getAlgorithmListeners().addListener(new StopWatch(),Priority.HIGH);
//    vra.getAlgorithmListeners().addListener(new AlgorithmSearchProgressChartListener("output/progress.png"));
    Collection<VehicleRoutingProblemSolution> solutions = vra.searchSolutions();
   
    SolutionPrinter.print(vrp, Solutions.bestOf(solutions), jsprit.core.reporting.SolutionPrinter.Print.VERBOSE);

View Full Code Here

    /*
     * solve the problem
     */
    VehicleRoutingAlgorithm vra = VehicleRoutingAlgorithms.readAndCreateAlgorithm(vrp, "input/algorithmConfigWithSchrimpfAcceptance.xml");
    vra.getAlgorithmListeners().addListener(new StopWatch(),Priority.HIGH);
    vra.getAlgorithmListeners().addListener(new AlgorithmSearchProgressChartListener("output/progress.png"));
    Collection<VehicleRoutingProblemSolution> solutions = vra.searchSolutions();
   
    SolutionPrinter.print(Solutions.bestOf(solutions));
   
View Full Code Here

TOP

Related Classes of jsprit.analysis.toolbox.StopWatch

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.