Ejemplo n.º 1
0
# Opus/UrbanSim urban simulation software.
# Copyright (C) 2005-2009 University of Washington
# See opus_core/LICENSE

from urbansim.simulation.run_simulation import RunSimulation
from urbansim.model_coordinators.model_system import ModelSystem
from randstad.run_config.randstad_baseline import run_configuration as my_configuration
from urbansim.configs.base_configuration import AbstractUrbansimConfiguration

config = AbstractUrbansimConfiguration()

simulation = RunSimulation()
run_configuration = config.copy()
run_configuration.merge(my_configuration)
simulation.prepare_and_run(run_configuration, 
                            simulation_instance=ModelSystem(),
                            remove_cache=True)
        'tables_to_cache_nchunks': {
                    'gridcells':4,
                    },
        },

    'scenario_database_configuration':ScenarioDatabaseConfiguration(
        database_name = 'GSPSRC_2000_baseyear_change_20060924_wlcm_init',
        ),

    'datasets_to_cache_after_each_model':['person'],
    'low_memory_mode':True,
    'base_year': 2000,
    'years': (2001,2001),
    "datasets_to_preload": {
        'gridcell': {},
        'job': {},                                            
        'person': {'package_name':'psrc'},
        'zone': {},
        'household': {},
        }
    }

from urbansim.simulation.run_simulation import RunSimulation
from urbansim.model_coordinators.model_system import ModelSystem

if __name__ == "__main__":
    simulation = RunSimulation()
    run_configuration.merge(config_changes)
    simulation.prepare_and_run(run_configuration, 
                               simulation_instance=ModelSystem(),
                               remove_cache=False)
Ejemplo n.º 3
0
# Opus/UrbanSim urban simulation software.
# Copyright (C) 2005-2009 University of Washington
# See opus_core/LICENSE

from sanfrancisco.configs.baseline import Baseline
#from config_for_multiple_runs import ConfigForMultipleRuns
from urbansim.simulation.run_simulation import RunSimulation
from urbansim.model_coordinators.model_system import ModelSystem

simulation = RunSimulation()
run_configuration = Baseline()
#run_configuration = ConfigForMultipleRuns()
simulation.prepare_and_run(run_configuration,
                           simulation_instance=ModelSystem(),
                           remove_cache=run_configuration.get(
                               'remove_cache', False))