59 #ifdef CHECK_MEMORY_LEAKS
61 #endif // CHECK_MEMORY_LEAKS
70 oc.
addCallExample(
"-b 0 -e 1000 -n net.xml -r routes.xml",
"start a simulation from time 0 to 1000 with given net and routes");
71 oc.
addCallExample(
"-c munich_config.cfg",
"start with a configuration file");
87 oc.
addDescription(
"net-file",
"Input",
"Load road network description from FILE");
91 oc.
addDescription(
"route-files",
"Input",
"Load routes descriptions from FILE(s)");
95 oc.
addDescription(
"additional-files",
"Input",
"Load further descriptions from FILE(s)");
99 oc.
addDescription(
"weight-files",
"Input",
"Load edge/lane weights for online rerouting from FILE");
101 oc.
addSynonyme(
"weight-attribute",
"measure",
true);
102 oc.
addDescription(
"weight-attribute",
"Input",
"Name of the xml attribute which gives the edge weight");
105 oc.
addDescription(
"load-state",
"Input",
"Loads a network state from FILE");
107 oc.
addDescription(
"load-state.offset",
"Input",
"Sets the time offset for vehicle segment exit times");
113 oc.
addDescription(
"netstate-dump",
"Output",
"Save complete network states into FILE");
115 oc.
addSynonyme(
"netstate-dump.empty-edges",
"netstate.empty-edges");
116 oc.
addSynonyme(
"netstate-dump.empty-edges",
"dump-empty-edges",
true);
117 oc.
addDescription(
"netstate-dump.empty-edges",
"Output",
"Write also empty edges completely when dumping");
121 oc.
addDescription(
"emission-output",
"Output",
"Save the emission values of each vehicle");
123 oc.
addDescription(
"fcd-output",
"Output",
"Save the Floating Car Data");
125 oc.
addDescription(
"fcd-output.geo",
"Output",
"Save the Floating Car Data using geo-coordinates (lon/lat)");
127 oc.
addDescription(
"fcd-output.signals",
"Output",
"Add the vehicle signal state to the FCD output (brake lights etc.)");
129 oc.
addDescription(
"full-output",
"Output",
"Save a lot of information for each timestep (very redundant)");
131 oc.
addDescription(
"queue-output",
"Output",
"Save the vehicle queues at the junctions (experimental)");
133 oc.
addDescription(
"vtk-output",
"Output",
"Save complete vehicle positions inclusive speed values in the VTK Format (usage: /path/out will produce /path/out_$TIMESTEP$.vtp files)");
138 oc.
addSynonyme(
"summary-output",
"emissions-output",
true);
139 oc.
addSynonyme(
"summary-output",
"emissions",
true);
140 oc.
addDescription(
"summary-output",
"Output",
"Save aggregated vehicle departure info into FILE");
144 oc.
addDescription(
"tripinfo-output",
"Output",
"Save single vehicle trip info into FILE");
148 oc.
addDescription(
"vehroute-output",
"Output",
"Save single vehicle route info into FILE");
151 oc.
addSynonyme(
"vehroute-output.exit-times",
"vehroutes.exit-times");
152 oc.
addDescription(
"vehroute-output.exit-times",
"Output",
"Write the exit times for all edges");
155 oc.
addSynonyme(
"vehroute-output.last-route",
"vehroutes.last-route");
156 oc.
addDescription(
"vehroute-output.last-route",
"Output",
"Write the last route only");
159 oc.
addSynonyme(
"vehroute-output.sorted",
"vehroutes.sorted");
160 oc.
addDescription(
"vehroute-output.sorted",
"Output",
"Sorts the output by departure time");
163 oc.
addDescription(
"vehroute-output.write-unfinished",
"Output",
"Write vehroute output for vehicles which have not arrived at simulation end");
166 oc.
addDescription(
"link-output",
"Output",
"Save links states into FILE");
169 oc.
addDescription(
"bt-output",
"Output",
"Save bt visibilities into FILE");
174 oc.
addDescription(
"movereminder-output",
"Output",
"Save movereminder states of selected vehicles into FILE");
176 oc.
addDescription(
"movereminder-output.vehicles",
"Output",
"List of vehicle ids which shall save their movereminder states");
180 oc.
addDescription(
"save-state.times",
"Output",
"Use INT[] as times at which a network state written");
182 oc.
addDescription(
"save-state.prefix",
"Output",
"Prefix for network states");
184 oc.
addDescription(
"save-state.files",
"Output",
"Files for network states");
188 oc.
addDescription(
"begin",
"Time",
"Defines the begin time; The simulation starts at this time");
191 oc.
addDescription(
"end",
"Time",
"Defines the end time; The simulation ends at this time");
193 #ifdef HAVE_SUBSECOND_TIMESTEPS
195 oc.
addDescription(
"step-length",
"Time",
"Defines the step duration");
201 oc.
addDescription(
"route-steps",
"Processing",
"Load routes for the next number of seconds ahead");
203 #ifdef HAVE_INTERNAL_LANES
205 oc.
addDescription(
"no-internal-links",
"Processing",
"Disable (junction) internal links");
208 oc.
addDescription(
"ignore-junction-blocker",
"Processing",
"Ignore vehicles which block the junction after they have been standing for SECONDS (-1 means never ignore)");
212 oc.
addDescription(
"ignore-accidents",
"Processing",
"Do not check whether accidents occure more deeply");
215 oc.
addDescription(
"ignore-route-errors",
"Processing",
"Do not check whether routes are connected");
218 oc.
addSynonyme(
"max-num-vehicles",
"too-many-vehicles",
true);
219 oc.
addDescription(
"max-num-vehicles",
"Processing",
"Quit simulation if this number of vehicles is exceeded");
222 oc.
addDescription(
"incremental-dua-step",
"Processing",
"Perform the simulation as a step in incremental DUA");
224 oc.
addDescription(
"incremental-dua-base",
"Processing",
"Base value for incremental DUA");
226 oc.
addDescription(
"scale",
"Processing",
"Scale demand by the given factor (0..1)");
229 oc.
addDescription(
"time-to-teleport",
"Processing",
"Specify how long a vehicle may wait until being teleported, defaults to 300, non-positive values disable teleporting");
231 oc.
addDescription(
"time-to-teleport.highways",
"Processing",
"The teleport time on highways");
234 oc.
addDescription(
"max-depart-delay",
"Processing",
"How long vehicles wait for departure before being skipped, defaults to -1 which means vehicles are never skipped");
237 oc.
addDescription(
"sloppy-insert",
"Processing",
"Whether insertion on an edge shall not be repeated in same step once failed");
240 oc.
addDescription(
"eager-insert",
"Processing",
"Whether each vehicle is checked separately for insertion on an edge");
243 oc.
addDescription(
"lanechange.allow-swap",
"Processing",
"Whether blocking vehicles trying to change lanes may be swapped");
246 oc.
addDescription(
"lanechange.duration",
"Processing",
"Duration of a lane change maneuver (default 0)");
250 "Select among routing algorithms ['dijkstra', 'astar']");
260 oc.
addDescription(
"no-duration-log",
"Report",
"Disable performance reports for individual simulation steps");
263 oc.
addDescription(
"no-step-log",
"Report",
"Disable console output of current simulation step");
270 oc.
addDescription(
"remote-port",
"TraCI Server",
"Enables TraCI Server if set");
273 oc.
addDescription(
"python-script",
"TraCI Server",
"Runs TraCI script with embedded python");
280 oc.
addDescription(
"mesosim",
"Mesoscopic",
"Enables mesoscopic simulation");
282 oc.
addDescription(
"meso-edgelength",
"Mesoscopic",
"Length of an edge segment in mesoscopic simulation");
284 oc.
addDescription(
"meso-tauff",
"Mesoscopic",
"Factor for calculating the free-free headway time");
286 oc.
addDescription(
"meso-taufj",
"Mesoscopic",
"Factor for calculating the free-jam headway time");
288 oc.
addDescription(
"meso-taujf",
"Mesoscopic",
"Factor for calculating the jam-free headway time");
290 oc.
addDescription(
"meso-taujj",
"Mesoscopic",
"Factor for calculating the jam-jam headway time");
292 oc.
addDescription(
"meso-jam-threshold",
"Mesoscopic",
"Minimum percentage of occupied space to consider a segment jammed. A negative argument causes thresholds to be computed based on edge speed and tauff (default)");
294 oc.
addDescription(
"meso-multi-queue",
"Mesoscopic",
"Enable multiple queues at edge ends");
296 oc.
addDescription(
"meso-junction-control",
"Mesoscopic",
"Enable mesoscopic traffic light and priority junction handling");
298 oc.
addDescription(
"meso-junction-control.limited",
"Mesoscopic",
"Enable mesoscopic traffic light and priority junction handling for saturated links. This prevents faulty traffic lights from hindering flow in low-traffic situations");
300 oc.
addDescription(
"meso-recheck",
"Mesoscopic",
"Time interval for rechecking insertion into the next segment after failure");
310 oc.
addDescription(
"gui-settings-file",
"GUI Only",
"Load visualisation settings from FILE");
313 oc.
addDescription(
"quit-on-end",
"GUI Only",
"Quits the GUI when the simulation stops");
316 oc.
addDescription(
"game",
"GUI Only",
"Start the GUI in gaming mode");
319 oc.
addDescription(
"start",
"GUI Only",
"Start the simulation after loading");
322 oc.
addDescription(
"disable-textures",
"GUI Only",
"Do not load background pictures");
326 oc.
addDescription(
"osg-view",
"GUI Only",
"Start with an OpenSceneGraph view instead of the regular 2D view");
361 if (!oc.
isSet(
"net-file")) {
365 if (oc.
isSet(
"incremental-dua-step") && oc.
isSet(
"incremental-dua-base")) {
366 WRITE_WARNING(
"The options 'incremental-dua-step' and 'incremental-dua-base' are deprecated, use 'scale' instead.");
367 if (oc.
getInt(
"incremental-dua-step") > oc.
getInt(
"incremental-dua-base")) {
378 if (oc.
getBool(
"vehroute-output.exit-times") && !oc.
isSet(
"vehroute-output")) {
379 WRITE_ERROR(
"A vehroute-output file is needed for exit times.");
382 if (oc.
isSet(
"gui-settings-file") &&
383 oc.
getString(
"gui-settings-file") !=
"" &&
388 if (oc.
getBool(
"meso-junction-control.limited") && !oc.
getBool(
"meso-junction-control")) {
389 oc.
set(
"meso-junction-control",
"true");
392 #ifdef HAVE_SUBSECOND_TIMESTEPS
399 if (oc.
isSet(
"movereminder-output.vehicles") && !oc.
isSet(
"movereminder-output")) {
400 WRITE_ERROR(
"option movereminder-output.vehicles requires option movereminder-output to be set");
404 if (oc.
getBool(
"sloppy-insert")) {
405 WRITE_WARNING(
"The option 'sloppy-insert' is deprecated, because it is now activated by default, see the new option 'eager-insert'.");
416 #ifdef HAVE_INTERNAL_LANES
434 MSGlobals::gMesoLimitedJunctionControl = oc.
getBool(
"meso-junction-control.limited");
436 MSGlobals::gUsingInternalLanes =
false;
440 #ifdef HAVE_SUBSECOND_TIMESTEPS
444 if (oc.
isSet(
"movereminder-output")) {
445 MSBaseVehicle::initMoveReminderOutput(oc);
static bool gOmitEmptyEdgesOnDump
Information whether empty edges shall be written on dump.
void doRegister(const std::string &name, Option *v)
Adds an option under the given name.
static void insertRandOptions()
Initialises the given options container with random number options.
static void addReportOptions(OptionsCont &oc)
Adds reporting options to the given container.
static void buildStreams()
Builds the streams used possibly by the simulation.
void addCallExample(const std::string &example, const std::string &desc)
Add a call example.
bool getBool(const std::string &name) const
Returns the boolean-value of the named option (only for Option_Bool)
static bool gStateLoaded
Information whether a state has been loaded.
SUMOReal getFloat(const std::string &name) const
Returns the SUMOReal-value of the named option (only for Option_Float)
static void addConfigurationOptions(OptionsCont &oc)
Adds configuration options to the given container.
#define WRITE_WARNING(msg)
static OptionsCont & getOptions()
Retrieves the options.
static bool gCheck4Accidents
static void fillOptions()
Inserts options used by the simulation into the OptionsCont-singleton.
void addSynonyme(const std::string &name1, const std::string &name2, bool isDeprecated=false)
Adds a synonyme for an options name (any order)
std::string getString(const std::string &name) const
Returns the string-value of the named option (only for Option_String)
static void init()
Static intialization.
std::vector< int > IntVector
Definition of a vector of unsigned ints.
bool isUsableFileList(const std::string &name) const
Checks whether the named option is usable as a file list (with at least a single file) ...
SUMOTime string2time(const std::string &r)
void addOptionSubTopic(const std::string &topic)
Adds an option subtopic.
static bool gUsingInternalLanes
Information whether the simulation regards internal lanes.
bool isDefault(const std::string &name) const
Returns the information whether the named option has still the default value.
static bool checkOptions()
Checks the set options.
static SUMOTime gTimeToGridlockHighways
bool set(const std::string &name, const std::string &value)
Sets the given value for the named option.
static bool createDeviceByOption(const std::string &optionName, const std::string &rootElement="")
Creates the device using the output definition stored in the named option.
A storage for options typed value containers)
static SUMOTime gTimeToGridlock
static void insertOptions(OptionsCont &oc)
Inserts options for building devices.
static SUMOTime gIgnoreJunctionBlocker
Information whether the simulation regards internal lanes.
static const bool gUseMesoSim
static void setMSGlobals(OptionsCont &oc)
Sets the global microsim-options.
void addDescription(const std::string &name, const std::string &subtopic, const std::string &description)
Adds a description for an option.
int getInt(const std::string &name) const
Returns the int-value of the named option (only for Option_Integer)
static SUMOTime gLaneChangeDuration
bool isSet(const std::string &name, bool failOnNonExistant=true) const
Returns the information whether the named option is set.