SUMO应用工具:NETGENERATE

NETGENERATE


原文链接:http://sumo.dlr.de/wiki/NETGENERATE

这个是用于生成路网文件的,和netconvert类似,不过netgenerate是自动生成全新的路网文件,而netconvert是将其他数据格式的路网文件转换成sumo可以读取的格式。两者不太一样。前面提到的格子网络(grid network)、蜘蛛网(spider network)、随机网络(random network)等,都是netgenerate的杰作。

 

1、简介

netgenerate生成sumo可以使用的路网文件。

目的:生成路网文件。

系统:win、linux

输入:命令行参数

输出:路网文件或者其他输出

编程语言:C++

2、用法描述

这部分主要介绍各种命令行参数的含义。

2.1配置Configuration

Option

Description

-c <FILE>
--configuration-file <FILE>

Loads the named config on startup

--save-configuration <FILE>

Saves current configuration into FILE

--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

2.2格子路网

Option

Description

-g <BOOL>
--grid <BOOL>

Forces NETGEN to build a grid-like network; default: false

--grid.number <INT>

The number of junctions in both dirs;default: 5

--grid.length <FLOAT>

The length of streets in both dirs;default: 100

--grid.x-number <INT>

The number of junctions in x-dir; Overrides --grid-number; default: 5

--grid.y-number <INT>

The number of junctions in y-dir; Overrides --grid-number; default: 5

--grid.x-length <FLOAT>

The length of horizontal streets; Overrides --grid-length; default: 100

--grid.y-length <FLOAT>

The length of vertical streets; Overrides --grid-length; default: 100

--grid.attach-length <FLOAT>

The length of streets attached at the boundary; 0 means no streets are attached; default: 0

--grid.alphanumerical-ids <BOOL>

The Ids of generated nodes use letters for the X axis; default: false

2.3蜘蛛路网Spider network

Option

Description

-s <BOOL>
--spider <BOOL>

Forces NETGEN to build a spider-net-like network; default: false

--spider.arm-number <INT>

The number of axes within the net;default: 13

--spider.circle-number <INT>

The number of circles of the net;default: 20

--spider.space-radius <FLOAT>

The distances between the circles;default: 100

--spider.omit-center <BOOL>

Omit the central node of the network;default: false

2.4随机路网Random Network

注意:不建议使用—rand.connectivity为1,因为有可能使程序终止。

Option

Description

-r <BOOL>
--rand <BOOL>

Forces NETGEN to build a random network; default: false

--rand.iterations <INT>

Describes how many times an edge shall be added to the net; default: 2000

--rand.bidi-probability <FLOAT>

Defines the probability to build a reverse edge; default: 1

--rand.max-distance <FLOAT>

The maximum distance for each edge;default: 250

--rand.min-distance <FLOAT>

The minimum distance for each edge;default: 100

--rand.min-angle <FLOAT>

The minimum angle for each pair of (bidirectional) roads; default:0.785398

--rand.num-tries <INT>

The number of tries for creating each node; default: 50

--rand.connectivity <FLOAT>

Probability for roads to continue at each node; default: 0.95

--rand.neighbor-dist1 <FLOAT>

Probability for a node having exactly 1 neighbor; default: 0

--rand.neighbor-dist2 <FLOAT>

Probability for a node having exactly 2 neighbors; default: 0

--rand.neighbor-dist3 <FLOAT>

Probability for a node having exactly 3 neighbors; default: 10

--rand.neighbor-dist4 <FLOAT>

Probability for a node having exactly 4 neighbors; default: 10

--rand.neighbor-dist5 <FLOAT>

Probability for a node having exactly 5 neighbors; default: 2

--rand.neighbor-dist6 <FLOAT>

Probability for a node having exactly 6 neighbors; default: 1

2.5输出Output

Option

Description

--output-prefix <STRING>

Prefix which is applied to all output files. The special string 'TIME' is replaced by the current time.

-o <FILE>
--output-file <FILE>

The generated net will be written to FILE

--plain-output-prefix <FILE>

Prefix of files to write plain xml nodes, edges and connections to

--junctions.join-output <FILE>

Writes information about joined junctions to FILE (can be loaded as additional node-file to reproduce joins

--amitran-output <FILE>

The generated net will be written to FILE using Amitran format

--matsim-output <FILE>

The generated net will be written to FILE using MATsim format

--opendrive-output <FILE>

The generated net will be written to FILE using OpenDRIVE format

--dlr-navteq-output <FILE>

The generated net will be written to dlr-navteq files with the given PREFIX

--output.street-names <BOOL>

Street names will be included in the output (if available); default: false

--output.original-names <BOOL>

Writes original names, if given, as parameter; default: false

--street-sign-output <FILE>

Writes street signs as POIs to FILE

2.6TLs创建Tls Buliding

Option

Description

--tls.set <STRING>

Interprets STR as list of junctions to be controlled by TLS

--tls.unset <STRING>

Interprets STR as list of junctions to be not controlled by TLS

--tls.guess <BOOL>

Turns on TLS guessing; default: false

--tls-guess.joining <BOOL>

Includes node clusters into guess;default: false

--tls.join <BOOL>

Tries to cluster tls-controlled nodes;default: false

--tls.join-dist <FLOAT>

Determines the maximal distance for joining traffic lights (defaults to 20); default: 20

--tls.uncontrolled-within <BOOL>

Do not control edges that lie fully within a joined traffic light. This may cause collisions but allows old traffic light plans to be used;default: false

--tls.cycle.time <INT>

Use INT as cycle duration; default:90

--tls.green.time <INT>

Use INT as green phase duration;default: 31

-D <FLOAT>
--tls.yellow.min-decel <FLOAT>

Defines smallest vehicle deceleration;default: 3

--tls.yellow.patch-small <BOOL>

Given yellow times are patched even if being too short; default: false

--tls.yellow.time <INT>

Set INT as fixed time for yellow phase durations; default: -1

--tls.left-green.time <INT>

Use INT as green phase duration for left turns (s). Setting this value to 0 disables additional left-turning phases; default: 6

--tls.half-offset <STRING>

TLSs in STR will be shifted by half-phase

--tls.quarter-offset <STRING>

TLSs in STR will be shifted by quarter-phase

--tls.default-type <STRING>

TLSs with unspecified type will use STR as their algorithm; default:static

2.7道路剔除Edge Removal

Option

Description

--keep-edges.min-speed <FLOAT>

Only keep edges with speed in meters/second > FLOAT; default: -1

--remove-edges.explicit <STRING>

Remove edges in STR

--keep-edges.explicit <STRING>

Only keep edges in STR

--keep-edges.input-file <FILE>

Only keep edges in FILE (Each id on a single line. Selection files from SUMO-GUI are also supported)

--remove-edges.input-file <FILE>

Remove edges in FILE. (Each id on a single line. Selection files from SUMO-GUI are also supported)

--keep-edges.in-boundary <STRING>

Only keep edges which are located within the given boundary (given either as CARTESIAN corner coordinates <xmin,ymin,xmax,ymax> or as polygon <x0,y0,x1,y1,...>)

--keep-edges.in-geo-boundary <STRING>

Only keep edges which are located within the given boundary (given either as GEODETIC corner coordinates <lon-min,lat-min,lon-max,lat-max> or as polygon <lon0,lat0,lon1,lat1,...>)

2.8非管制节点UnregulatedNodes

Option

Description

--keep-nodes-unregulated <BOOL>

All nodes will be unregulated;default: false

--keep-nodes-unregulated.explicit <STRING>

Do not regulate nodes in STR

--keep-nodes-unregulated.district-nodes <BOOL>

Do not regulate district nodes;default: false

2.9处理

一般,netconvert和netgenerate都可以处理路网文件,将做左下角的节点作为原点。下面的这些命令允许不按照这种方式进行偏移。如果给出了明确的偏移,那么归一化是自动禁止的。

Option

Description

--no-internal-links <BOOL>

Omits internal links; default: false

--numerical-ids <BOOL>

Remaps alphanumerical IDs of nodes and edges to ensure that all IDs are integers; default: false

--no-turnarounds <BOOL>

Disables building turnarounds;default: false

--no-turnarounds.tls <BOOL>

Disables building turnarounds at tls-controlled junctions; default: false

--no-left-connections <BOOL>

Disables building connections to left;default: false

--offset.disable-normalization <BOOL>

Turn off normalizing node positions;default: false

--offset.x <FLOAT>

Adds FLOAT to net x-positions;default: 0

--offset.y <FLOAT>

Adds FLOAT to net y-positions;default: 0

--flip-y-axis <BOOL>

Flips the y-coordinate along zero;default: false

--roundabouts.guess <BOOL>

Enable roundabout-guessing; default:false

--opposites.guess <BOOL>

Enable guessing of opposite direction lanes usable for overtaking; default:false

--lefthand <BOOL>

Assumes left-hand traffic on the network; default: false

--edges.join <BOOL>

Merges edges which connect the same nodes and are close to each other (recommended for VISSIM import);default: false

--junctions.join <BOOL>

Joins junctions that are close to each other (recommended for OSM import);default: false

--junctions.join-dist <FLOAT>

Determines the maximal distance for joining junctions (defaults to 10);default: 10

--junctions.corner-detail <INT>

Generate INT intermediate points to smooth out intersection corners;default: 0

--junctions.internal-link-detail <INT>

Generate INT intermediate points to smooth out lanes within the intersection; default: 5

--junctions.scurve-stretch <FLOAT>

Generate longer intersections to allow for smooth s-curves when the number of lanes changes; default: 0

--rectangular-lane-cut <BOOL>

Forces rectangular cuts between lanes and intersections; default: false

--check-lane-foes.roundabout <BOOL>

Allow driving onto a multi-lane road if there are foes on other lanes (at roundabouts); default: true

--check-lane-foes.all <BOOL>

Allow driving onto a multi-lane road if there are foes on other lanes (everywhere); default: false

--sidewalks.guess <BOOL>

Guess pedestrian sidewalks based on edge speed; default: false

--sidewalks.guess.max-speed <FLOAT>

Add sidewalks for edges with a speed equal or below the given limit;default: 13.89

--sidewalks.guess.min-speed <FLOAT>

Add sidewalks for edges with a speed above the given limit; default: 5.8

--sidewalks.guess.from-permissions <BOOL>

Add sidewalks for edges that allow pedestrians on any of their lanes regardless of speed; default: false

--sidewalks.guess.exclude <STRING>

Do not guess sidewalks for the given list of edges

--crossings.guess <BOOL>

Guess pedestrian crossings based on the presence of sidewalks; default:false

--crossings.guess.speed-threshold <FLOAT>

At uncontrolled nodes, do not build crossings across edges with a speed above the threshold; default: 13.89

2.10构建默认值BulidingDefaults

Option

Description

-L <INT>
--default.lanenumber <INT>

The default number of lanes in an edge;default: 1

--default.lanewidth <FLOAT>

The default width of lanes; default: -1

-S <FLOAT>
--default.speed <FLOAT>

The default speed on an edge (in m/s);default: 13.9

-P <INT>
--default.priority <INT>

The default priority of an edge; default:-1

--default.sidewalk-width <FLOAT>

The default width of added sidewalks;default: 2

--default.disallow <STRING>

The default for disallowed vehicle classes

--default.junctions.keep-clear <BOOL>

Whether junctions should be kept clear by default; default: true

--default.junctions.radius <FLOAT>

The default turning radius of intersections; default: 1.5

-j <STRING>
--default-junction-type <STRING>

[traffic_light|priority|right_before_left] Determines the type of the build junctions

2.11报告Report

很多的sumo软件有相同的报告参数设置。详细可以阅读:Basics/Usingthe 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; 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", "auto" or "always");default: auto

--xml-validation.net <STRING>

Set schema validation scheme of SUMO network inputs ("never", "auto" or "always"); default: never

-W <BOOL>
--no-warnings <BOOL>

Disables output of warnings; default:false

-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

2.11随机数random number

同上。详细阅读: Basics/Using the Command LineApplications#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

 

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值