src/model/ModelCLI.java
public static void main(String[] args) throws Exception {
        if (args.length < 1) {
            System.err.println("Missing argument, please provide a parameter file.");
            System.exit(1);
        }

        Parameters parameters = new Parameters(args[0]);
        Model model = new Model(parameters);
        
        for (int i = 0; i < parameters.rounds; i++) {
            model.doIteration();
            if (i % parameters.dumpFrequency == 0) {
                dumpHeatMap(model.world);
            }
        }
        
        model.stop();
        dumpHeatMap(model.world);
    }
/**
     * Run the model headless for higher performance. Output is
     * written to stdout, including the periodic heatmap dumps.
     */
Run the model headless for higher performance. Output is
written to stdout, including the periodic heatmap dumps.
Run the model headless for higher performance . Output is written to stdout including the periodic heatmap dumps .
public static void main(String[] args) throws Exception {
        if (args.length < 1) {
            System.err.println("Missing argument, please provide a parameter file.");
            System.exit(1);
        }
        Parameters parameters = new Parameters(args[0]);
        Model model = new Model(parameters);
        for (int i = 0; i < parameters.rounds; i++) {
            model.doIteration();
            if (i % parameters.dumpFrequency == 0) {
                dumpHeatMap(model.world);
            }
        }
        model.stop();
        dumpHeatMap(model.world);
    }
public static void main ( String [ ] args ) throws Exception { if ( args . length < 1 ) { System . err . println ( "Missing argument, please provide a parameter file." ) ; System . exit ( 1 ) ; } Parameters parameters = new Parameters ( args [ 0 ] ) ; Model model = new Model ( parameters ) ; for ( int i = 0 ; i < parameters . rounds ; i ++ ) { model . doIteration ( ) ; if ( i % parameters . dumpFrequency == 0 ) { dumpHeatMap ( model . world ) ; } } model . stop ( ) ; dumpHeatMap ( model . world ) ; }
Run the model headless for higher performance.
Run the model headless for higher performance .