next up previous index
Next: Creating Indicator Objects Up: Constructing a Batch of Previous: Constructing a Batch of   Index


Constructing the SourceData object

The first step is to construct a SourceData object. The SourceData specifies the location of the simulation results that should be used for computing the indicators, the years for which the indicators should be computed, and, optionally, a second data directory for which the indicators will be compared against. Each indicator requires a source data object to be passed to it. Every SourceData object accepts the following arguments:

Here is an example. All indicators that use this SourceData object, and don't override the default, will be computed for 2010, 2015, and 2018.

source_data = SourceData(
   cache_directory = r'D:\urbansim_cache\run_1090.2006_11_14_12_12',
   comparison_cache_directory = r'D:\urbansim_cache\run_1091.2006_11_14_12_12',
   years = [2010, 2015, 2018],
   dataset_pool_configuration = DatasetPoolConfiguration(
         package_order=['urbansim','opus_core'],
         package_order_exceptions={},
         ),                  
)

The package_order parameter to dataset_pool_configuration needs to include all packages that the relevant indicators are defined for. For example, to include all indicators available for the Eugene application of UrbanSim, package_order=['eugene', 'urbansim', 'opus_core'].


next up previous index
Next: Creating Indicator Objects Up: Constructing a Batch of Previous: Constructing a Batch of   Index
info (at) urbansim.org