Generate a SUMO scenario with Trucks trips in the province of Brescia
SUMO Scenario generation: Trucks in the province of Brescia
More Details
Visum to SUMO network Conversion
netconvert -v --visum-file visum.net -o bsprov.net.xml.gz --visum.language-file=/home/lorenzo/src/sumo/data/lang/visumEN.txt --proj.utm --taz-output bsprov.taz.xml
➜ datiTrafficoBrescia git:(main) ✗ netconvert -v --visum-file visum.net -o bsprov.net.xml.gz --visum.language-file=/home/lorenzo/src/sumo/data/lang/visumEN.txt --proj.utm --taz-output bsprov.taz.xml
Found: $TSYS: at line 50
Found: $POINT: at line 97
Found: $EDGE: at line 144
Found: $FACEITEM: at line 29462
Found: $SURFACEITEM: at line 29553
Found: $NODE: at line 29600
Found: $ZONE: at line 80042
Found: $LINKTYPE: at line 80086
Found: $LINK: at line 80191
Found: $LINKPOLY: at line 205914
Found: $TURN: at line 383353
Found: $CONNECTOR: at line 734010
Parsing TSYS ... done.
Parsing LINKTYPE ...
Warning: Encountered unknown vehicle category 'putw' in type '30'
Warning: Encountered unknown vehicle category 'putw' in type '31'
Warning: Encountered unknown vehicle category 'putw' in type '32'
Warning: Encountered unknown vehicle category 'putw' in type '33'
Warning: Encountered unknown vehicle category 'putw' in type '34'
done.
Parsing NODE ... done.
Parsing ZONE ... done.
Parsing POINT ... done.
Parsing LINK ... done.
Parsing EDGE ... done.
Parsing CONNECTOR ... done.
Parsing TURN ... done.
Parsing LINKPOLY ... done.
Parsing SURFACEITEM ... done.
Parsing FACEITEM ... done.
Import done:
39 districts loaded.
50437 nodes loaded.
100 types loaded.
104819 edges loaded.
Proj projection parameters used: '+proj=utm +zone=32 +ellps=WGS84 +datum=WGS84 +units=m +no_defs'.
Removing self-loops ... done (4ms).
Removing empty nodes ... done (83ms).
28 nodes removed.
Moving network to origin ... done (185ms).
Computing turning directions ... done (74ms).
Assigning nodes to traffic lights ... done (0ms).
Warning: Found sharp turn with radius 6.13 at the start of edge '-10529'.
Warning: Found sharp turn with radius 4.10 at the end of edge '-11028'.
Warning: Found sharp turn with radius 7.30 at the start of edge '-11234'.
Warning: Found sharp turn with radius 7.14 at the start of edge '-12160'.
Warning: Found sharp turn with radius 4.23 at the start of edge '-12389'.
Warning: Found angle of 102.15 degrees at edge '-14872', segment 5.
Warning: Found angle of 134.54 degrees at edge '-16072', segment 11.
Warning: Found angle of 107.51 degrees at edge '-17089', segment 11.
Warning: Found angle of 131.54 degrees at edge '-17287', segment 3.
Warning: Found angle of 107.60 degrees at edge '-18536', segment 1.
Sorting nodes' edges ... done (82ms).
Computing node shapes ...
Warning: Shape for junction '11372' has distance 24.00 to its given position.
Warning: Shape for junction '1230' has distance 22.05 to its given position.
Warning: Shape for junction '14499' has distance 21.48 to its given position.
Warning: Shape for junction '15590' has distance 37.84 to its given position.
Warning: Shape for junction '15597' has distance 28.14 to its given position.
done (1195ms).
Computing edge shapes ... done (465ms).
Computing node types ... done (44ms).
Computing priorities ... done (94ms).
Computing approached edges ... done (107ms).
Guessing and setting roundabouts ...
Guessed 886 roundabout(s).
done (43ms).
Computing approaching lanes ... done (363ms).
Dividing of lanes on approached lanes ... done (178ms).
Processing turnarounds ... done (80ms).
Rechecking of lane endings ... done (58ms).
Computing traffic light control information ... done (19ms).
Computing node logics ... done (356ms).
Computing traffic light logics ... done (0ms).
0 traffic light(s) computed.
Building inner edges ...
Warning: Speed of straight connection '-54454_0->50542_0' reduced by 11.93 due to turning radius of 45.67 (length=7.66, angle=24.77).
Warning: Speed of straight connection '-50542_0->54454_0' reduced by 13.41 due to turning radius of 37.53 (length=6.27, angle=24.77).
Warning: Speed of straight connection '-41675_0->-10459_0' reduced by 7.68 due to turning radius of 31.45 (length=11.45, angle=36.41).
Warning: Speed of straight connection '1155_0->16458_0' reduced by 7.57 due to turning radius of 74.24 (length=15.78, angle=27.31).
Warning: Speed of turning connection '1155_0->16101_0' reduced by 22.25 due to turning radius of 5.55 (length=11.18, angle=149.89).
Warning: Connection '40856_0->40860_0' is only 0.07m short.
Warning: Intersecting left turns at junction '11474' from lane '12126_0' and lane '12125_0' (increase junction radius to avoid this).
Warning: Intersecting left turns at junction '13317' from lane '14330_0' and lane '-14329_0' (increase junction radius to avoid this).
Warning: Intersecting left turns at junction '1667' from lane '-27718_0' and lane '-1917_0' (increase junction radius to avoid this).
Warning: Intersecting left turns at junction '17875' from lane '13868_0' and lane '-13869_0' (increase junction radius to avoid this).
Warning: Intersecting left turns at junction '18470' from lane '-53836_0' and lane '-20324_0' (increase junction radius to avoid this).
done (1207ms).
-----------------------------------------------------
Summary:
Node type statistics:
Unregulated junctions : 0
Dead-end junctions : 84
Priority junctions : 49814
Right-before-left junctions : 511
Network boundaries:
Original boundary : 10.03,45.27,10.53,45.75
Applied offset : -579969.06,-5013364.07
Converted boundary : 0.00,0.00,40129.94,54103.61
-----------------------------------------------------
Writing network ... done (4096ms).
Warning: 50 total messages of type: Encountered unknown vehicle category 'putw' in type '%'
Warning: 168 total messages of type: Found angle of % degrees at edge '%', segment %.
Warning: 940 total messages of type: Found sharp turn with radius % at the % of edge '%'.
Warning: 14 total messages of type: Intersecting left turns at junction '%' from lane '%' and lane '%' (increase junction radius to avoid this).
Warning: 22 total messages of type: Shape for junction '%' has distance % to its given position.
Warning: 6828 total messages of type: Speed of % connection '%' reduced by % due to turning radius of % (length=%, angle=%).
Success.
Demand: define trips starting from OD matrix
https://sumo.dlr.de/docs/Demand/Introduction_to_demand_modelling_in_SUMO.html
od2trips -v --taz-files bsprov.taz.xml.gz --od-matrix-files bsprovOD.vmat -o bsprov.trips.xml --vtype truck --human-readable-time true --begin 25200 --end 28800
Loading districts from 'bsprov.taz.xml' ... done.
Reading matrix 'bsprovOD.vmat' stored as VMR ... done.
5507.64 vehicles loaded.
0.00 vehicles discarded.
5510.00 vehicles written.
Success.
duarouter -v --net-file bsprov.net.xml.gz -o duarouter.out.xml --additional-files bsprov.taz.xml --route-files vtypes.rou.xml,bsprov.trips.xml --with-taz true --repair true --ignore-errors true
prov.taz.xml --route-files vtypes.rou.xml,bsprov.trips.xml --with-taz true --repair true --ignore-errors true
Loading net ... done.
Loading additional file 'bsprov.taz.xml' ... done.
Skipped until: 25200.77
Routes found between time steps 25200.77 and 28799.23.
DijkstraRouter answered 5510 queries and explored 57410.27 edges on average.
DijkstraRouter spent 196.54s answering queries (35.67ms on average).
Success.
204.04s user 0.33s system 99% cpu 3:24.40 total
marouter -v --net-file bsprov.net.xml.gz -o marouter.out.xml --additional-files bsprov.taz.xml --route-files vtypes.rou.xml,bsprov.trips.xml --with-taz true --max-iterations 20
Loading net ... done.
Loading additional file 'bsprov.taz.xml' ... done.
Loading routes and trips from 'vtypes.rou.xml' ... done.
Loading routes and trips from 'bsprov.trips.xml' ... done.
5510.00 valid vehicles loaded (total seen: 5510.00).
starting interval 25200.00
starting iteration 0
starting iteration 1
starting iteration 2
starting iteration 3
starting iteration 4
starting iteration 5
starting iteration 6
starting iteration 7
starting iteration 8
starting iteration 9
starting iteration 10
starting iteration 11
starting iteration 12
starting iteration 13
starting iteration 14
starting iteration 15
starting iteration 16
starting iteration 17
starting iteration 18
starting iteration 19
DijkstraRouter answered 16644 queries and explored 4399.18 edges on average.
DijkstraRouter spent 23.00s answering queries (1.38ms on average).
Success.
31.74s user 0.29s system 99% cpu 32.055 total
Running Simulation
sumo -c bsprov.sumocfg --edgedata-output edge.stats.xml --summary summary.stats.xml --statistic-output statistic.stats.xml --output-prefix bsprovout/bs$(date +"%d-%m-%y_%T")
Step #26800.00Warning: Vehicle '832' performs emergency braking on lane '23502_0' with decel=7.00, wished=4.00, severity=1.00, time=26800.00.
Warning: Vehicle '5426' performs emergency braking on lane '43801_0' with decel=7.00, wished=4.00, severity=1.00, time=27858.00.
Warning: Vehicle '4025' performs emergency braking on lane '-57080_0' with decel=7.00, wished=4.00, severity=1.00, time=27967.00.
Warning: Vehicle '137' performs emergency braking on lane '23502_0' with decel=7.00, wished=4.00, severity=1.00, time=28047.00.
Warning: Vehicle '4017' performs emergency braking on lane '-57080_0' with decel=7.00, wished=4.00, severity=1.00, time=28193.00.
Warning: Teleporting vehicle '4812'; waited too long (wrong lane), lane='45902_1', time=28255.00.
Warning: Vehicle '4812' ends teleporting on edge '21621', time=28255.00.
Warning: Teleporting vehicle '3090'; waited too long (wrong lane), lane='45902_0', time=28567.00.
Warning: Teleporting vehicle '3670'; waited too long (wrong lane), lane='45902_1', time=28567.00.
Warning: Vehicle '3670' ends teleporting on edge '21621', time=28567.00.
Warning: Vehicle '3090' ends teleporting on edge '28898', time=28567.00.
Step #86400.00 (0ms ?*RT. ?UPS, vehicles TOT 5510 ACT 0 BUF 0)
106.70s user 0.78s system 99% cpu 1:47.51 total
NB: edit bsprov.sumocfg
to choose to use duarouter.out.xml
or marouter.out.xml
files as demand-definition
Configuring OUTPUT
https://sumo.dlr.de/docs/Simulation/Output/index.html
CONTA MACCHINE https://sumo.dlr.de/docs/Simulation/Output/Induction_Loops_Detectors_%28E1%29.html
DA METTERE PRIMA E DOPO IL PONTE? :) https://sumo.dlr.de/docs/Simulation/Output/RouteProbe.html
https://sumo.dlr.de/docs/Simulation/Output/Lane-_or_Edge-based_Traffic_Measures.html
https://sumo.dlr.de/docs/Simulation/Output/Summary.html