od2trips

# From 30.000 feet

od2trips imports O/D-matrices and splits them into single vehicle trips.

- Purpose: Conversion of O/D-matrices to single vehicle trips
- System: portable (Linux/Windows is tested); runs on command line
- Input (mandatory):
  - A) O/D-Matrix
  - B) a set of districts
- Output: A list of vehicle trip definitions
- Programming Language: C++

# Usage Description

od2trips maps traffic that is defined via origin and destination zones onto the edges of a network. For details, see Demand/Importing_O/D_Matrices.

## Options

You may use a XML schema definition file for setting up a od2trips configuration: od2tripsConfiguration.xsd.

### Configuration

All applications of the SUMO-suite handle configuration options the same way. These options are discussed at Basics/Using the Command Line Applications#Configuration Files.

Option | Description
--- | ---
-c <FILE> --configuration-file <FILE> | Loads the named config on startup
-C <FILE> --save-configuration <FILE> | Saves current configuration into FILE
--save-configuration.relative <BOOL> | Enforce relative paths when saving the configuration; default: false
--save-template <FILE> | Saves a configuration template (empty) into FILE
--save-schema <FILE> | Saves the configuration schema into FILE
--save-commented <BOOL> | Adds comments to saved template, configuration, or schema; default: false

### Input

Option | Description
--- | ---
-n <FILE> --taz-files <FILE> | Loads TAZ (districts; also from networks) from FILE(s)
-d <FILE> --od-matrix-files <FILE> | Loads O/D-files from FILE(s)
--od-amitran-files <FILE> | Loads O/D-matrix in Amitran format from FILE(s)
-z <FILE> --tazrelation-files <FILE> | Loads O/D-matrix in tazRelation format from FILE(s)
--tazrelation-attribute <STRING> | Define data attribute for loading counts (default 'count'); default: count

### Output

Option | Description
--- | ---
--write-license <BOOL> | Include license info into every output file; default: false
--output-prefix <STRING> | Prefix which is applied to all output files. The special string 'TIME' is replaced by the current time.
--precision <INT> | Defines the number of digits after the comma for floating point output; default: 2
--precision.geo <INT> | Defines the number of digits after the comma for lon,lat output; default: 6
-H <BOOL> --human-readable-time <BOOL> | Write time values as hour:minute:second or day:hour:minute:second rather than seconds; default: false
-o <FILE> --output-file <FILE> | Writes trip definitions into FILE
--flow-output <FILE> | Writes flow definitions into FILE
--flow-output.probability <BOOL> | Writes probabilistic flow instead of evenly spaced flow; default: false
--pedestrians <BOOL> | Writes pedestrians instead of vehicles; default: false
--persontrips <BOOL> | Writes persontrips instead of vehicles; default: false
--persontrips.modes | Add modes attribute to personTrips
--ignore-vehicle-type <BOOL> | Does not save vtype information; default: false
--junctions <BOOL> | Writes trips between junctions; default: false

### Time

Option | Description
--- | ---
-b <TIME> --begin <TIME> | Defines the begin time; Previous trips will be discarded; default: 0
-e <TIME> --end <TIME> | Defines the end time; Later trips will be discarded; Defaults to the maximum time that SUMO can represent; default: -1

### Processing

Option | Description
--- | ---
-s <FLOAT> --scale <FLOAT> | Scales the loaded flows by FLOAT; default: 1
--spread.uniform <BOOL> | Spreads trips uniformly over each time period; default: false
--different-source-sink <BOOL> | Always choose source and sink edge which are not identical; default: false
--vtype <STRING> | Defines the name of the vehicle type to use
--prefix <STRING> | Defines the prefix for vehicle names
--timeline | Uses STR[] as a timeline definition
--timeline.day-in-hours <BOOL> | Uses STR as a 24h-timeline definition; default: false
--no-step-log <BOOL> | Disable console output of current time step; default: false

### Defaults

Option | Description
--- | ---
--departlane <STRING> | Assigns a default depart lane; default: free
--departpos <STRING> | Assigns a default depart position
--departspeed <STRING> | Assigns a default depart speed; default: max
--arrivallane <STRING> | Assigns a default arrival lane
--arrivalpos <STRING> | Assigns a default arrival position
--arrivalspeed <STRING> | Assigns a default arrival speed

### Report

All applications of the SUMO-suite handle most of the reporting options the same way. These options are discussed at Basics/Using the Command Line Applications#Reporting Options.

Option | Description
--- | ---
-v <BOOL> --verbose <BOOL> | Switches to verbose output; default: false
--print-options <BOOL> | Prints option values before processing; default: false
-? <BOOL> --help <BOOL> | Prints this screen or selected topics; default: false
-V <BOOL> --version <BOOL> | Prints the current version; default: false
-X <STRING> --xml-validation <STRING> | Set schema validation scheme of XML inputs ("never", "local", "auto" or "always"); default: local
-W <BOOL> --no-warnings <BOOL> | Disables output of warnings; default: false
--aggregate-warnings <INT> | Aggregate warnings of the same type whenever more than INT occur; default: -1
-l <FILE> --log <FILE> | Writes all messages to FILE (implies verbose)
--message-log <FILE> | Writes all non-error messages to FILE (implies verbose)
--error-log <FILE> | Writes all warnings and errors to FILE
--ignore-errors <BOOL> | Continue on broken input; default: false

### Random Number

All applications of the SUMO-suite handle randomisation options the same way. These options are discussed at Basics/Using the Command Line Applications#Random Number Options.

Option | Description
--- | ---
--random <BOOL> | Initialises the random number generator with the current system time; default: false
--seed <INT> | Initialises the random number generator with the given value; default: 23423

# Notes

- The option --vtype only works when "--od-matrix-files" is used. For "Amitran" format, this is given by the "id" property of "actorConfig".
- With use of netedit it is possible to observe the demand amount distribution of edge-based or TAZ-based relations network/TAZ related data.

#### Search

Enter your search terms:

#### Keyboard Shortcuts

Key | Action
--- | ---
`?` | Open this help dialog
`s` | Search the Documentation
`e` | Edit current page on GitHub