Re: [sumo-user] Measure Road Efficiency - SUMO Traci

Jakob, many thanks for your prompt response.

I calculated the aggregated edge data using <edgeData id="dump_15" freq="30" file="edge_data.xml" excludeEmpty="true"/> and then used this command to "\visualization>plotXMLAttributes.py edge_data.xml -i id -x density -y timeLoss -s --scatterplot --legend --yfactor 60 --ylabel TimeLoss" to plot the attached graph of density versus time loss.

I would be thankful if you could answer the following queries:

1. Why the value of time loss is too large (1000) on the graph when the maximum value of time loss is 15 in the attached edgedata output file.
2. Can we aggregate the values of all the edges and plot them or how can we get the output of selective edges?
3. How can we draw a line graph using plotXMLAttributes.py
4. What do "-i id" and "-s" represent in the above command.
5. Does it make sense if we draw a relation between the density and the time loss.

Thank you

On Tue, 15 Feb 2022 at 10:41, Jakob Erdmann <namdre.sumo@xxxxxxxxx> wrote:
1. TraCI is not tailored for measuring aggregated data. I recommend doing this with XML outputs (i.e https://sumo.dlr.de/docs/Simulation/Output/Lane-_or_Edge-based_Traffic_Measures.html). However, you can compute traffic statistics "manually":
- retrieve the speed or timeLoss of all vehicles in every step
- compute vehicle density (lane.getLastStepVehicleNumber / lane.getLength)
2. you could run simulations with and without your special delay-causing vehicle and observe the difference

Am Mo., 14. Feb. 2022 um 14:24 Uhr schrieb Sumbal Malik <maliksumbal01@xxxxxxxxx>:
Dear SUMO Team

1. How can we calculate/measure the traffic/road efficiency using traci SUMO
2. Can we draw a relationship between the delay caused by an individual vehicle and traffic efficiency of the road segment.

Thank you

_______________________________________________
sumo-user mailing list
sumo-user@xxxxxxxxxxx
To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/sumo-user
_______________________________________________
sumo-user mailing list
sumo-user@xxxxxxxxxxx
To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/sumo-user
```<?xml version="1.0" encoding="UTF-8"?>

<!-- generated on 2022-02-15 17:40:49 by Eclipse SUMO GUI Version 1.12.0
<configuration xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; xsi:noNamespaceSchemaLocation="http://sumo.dlr.de/xsd/sumoConfiguration.xsd";>

<input>
<net-file value="a.net.xml"/>
<route-files value="a.rou.xml"/>
</input>

<output>
<fcd-output value="fcd_output.xml"/>
<fcd-output.geo value="true"/>
<fcd-output.distance value="true"/>
<fcd-output.acceleration value="true"/>
<summary-output value="summary_output.xml"/>
<tripinfo-output value="tripinfo_output.xml"/>
<lanechange-output value="lanechange_output.xml"/>
</output>

<processing>
<lateral-resolution value="1"/>
</processing>

<report>
<verbose value="true"/>
<log value="statlog_output.txt"/>
<duration-log.statistics value="true"/>
</report>

<traci_server>
<remote-port value="54403"/>
</traci_server>

</configuration>
-->

<meandata xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; xsi:noNamespaceSchemaLocation="http://sumo.dlr.de/xsd/meandata_file.xsd";>
<interval begin="0.00" end="30.00" id="dump_15">
<edge id="e1" sampledSeconds="28.00" traveltime="84.60" overlapTraveltime="86.01" density="3.11" laneDensity="1.56" occupancy="0.78" waitingTime="0.00" timeLoss="8.14" speed="3.55" speedRelative="0.26" departed="1" arrived="0" entered="0" left="0" laneChangedFrom="0" laneChangedTo="0"/>
</interval>
<interval begin="30.00" end="60.00" id="dump_15">
<edge id="e1" sampledSeconds="30.00" traveltime="65.58" overlapTraveltime="66.67" density="3.33" laneDensity="1.67" occupancy="0.83" waitingTime="0.00" timeLoss="2.55" speed="4.57" speedRelative="0.33" departed="0" arrived="0" entered="0" left="0" laneChangedFrom="0" laneChangedTo="0"/>
</interval>
<interval begin="60.00" end="90.00" id="dump_15">
<edge id="e1" sampledSeconds="70.99" traveltime="75.07" overlapTraveltime="78.63" density="7.89" laneDensity="3.94" occupancy="1.90" waitingTime="0.00" timeLoss="15.91" speed="3.88" speedRelative="0.28" departed="2" arrived="0" entered="0" left="1" laneChangedFrom="1" laneChangedTo="1"/>
<edge id="e2" sampledSeconds="17.33" traveltime="1040.89" overlapTraveltime="1058.23" density="1.93" laneDensity="0.96" occupancy="0.45" waitingTime="0.00" timeLoss="2.35" speed="0.29" speedRelative="0.02" departed="0" arrived="0" entered="1" left="0" laneChangedFrom="0" laneChangedTo="0"/>
</interval>
<interval begin="90.00" end="120.00" id="dump_15">
<edge id="e1" sampledSeconds="60.00" traveltime="64.79" overlapTraveltime="65.87" density="6.67" laneDensity="3.33" occupancy="1.67" waitingTime="0.00" timeLoss="4.44" speed="4.63" speedRelative="0.33" departed="0" arrived="0" entered="0" left="0" laneChangedFrom="0" laneChangedTo="0"/>
<edge id="e2" sampledSeconds="30.00" overlapTraveltime="100000.00" density="3.33" laneDensity="1.67" occupancy="0.83" waitingTime="0.00" timeLoss="0.00" speed="0.00" speedRelative="0.00" departed="0" arrived="0" entered="0" left="0" laneChangedFrom="0" laneChangedTo="0"/>
</interval>
<interval begin="120.00" end="150.00" id="dump_15">
<edge id="e1" sampledSeconds="26.00" traveltime="69.83" overlapTraveltime="72.09" density="2.89" laneDensity="1.44" occupancy="0.69" waitingTime="0.00" timeLoss="4.00" speed="4.23" speedRelative="0.30" departed="0" arrived="0" entered="0" left="2" laneChangedFrom="1" laneChangedTo="1"/>
<edge id="e2" sampledSeconds="66.66" traveltime="120.27" overlapTraveltime="122.27" density="7.41" laneDensity="3.70" occupancy="1.81" waitingTime="0.00" timeLoss="3.41" speed="2.49" speedRelative="0.18" departed="0" arrived="0" entered="2" left="0" laneChangedFrom="1" laneChangedTo="1"/>
</interval>
<interval begin="150.00" end="180.00" id="dump_15">
<edge id="e2" sampledSeconds="90.00" traveltime="95.88" overlapTraveltime="97.48" density="10.00" laneDensity="5.00" occupancy="2.50" waitingTime="0.00" timeLoss="7.68" speed="3.13" speedRelative="0.23" departed="0" arrived="0" entered="0" left="0" laneChangedFrom="0" laneChangedTo="0"/>
</interval>
<interval begin="180.00" end="210.00" id="dump_15">
<edge id="e2" sampledSeconds="66.95" traveltime="66.64" overlapTraveltime="67.70" density="7.44" laneDensity="3.72" occupancy="1.83" waitingTime="0.00" timeLoss="6.63" speed="4.50" speedRelative="0.32" departed="0" arrived="0" entered="0" left="2" laneChangedFrom="0" laneChangedTo="0"/>
<edge id="e3" sampledSeconds="25.18" traveltime="85.90" overlapTraveltime="86.97" density="2.10" laneDensity="1.05" occupancy="0.50" waitingTime="0.00" timeLoss="1.73" speed="4.66" speedRelative="0.34" departed="0" arrived="0" entered="2" left="0" laneChangedFrom="0" laneChangedTo="0"/>
</interval>
<interval begin="210.00" end="240.00" id="dump_15">
<edge id="e2" sampledSeconds="30.00" traveltime="65.72" overlapTraveltime="66.82" density="3.33" laneDensity="1.67" occupancy="0.83" waitingTime="0.00" timeLoss="2.61" speed="4.56" speedRelative="0.33" departed="0" arrived="0" entered="0" left="0" laneChangedFrom="0" laneChangedTo="0"/>
<edge id="e3" sampledSeconds="60.00" traveltime="87.56" overlapTraveltime="88.65" density="5.00" laneDensity="2.50" occupancy="1.25" waitingTime="0.00" timeLoss="5.18" speed="4.57" speedRelative="0.33" departed="0" arrived="0" entered="0" left="0" laneChangedFrom="0" laneChangedTo="0"/>
</interval>
<interval begin="240.00" end="270.00" id="dump_15">
<edge id="e2" sampledSeconds="5.13" traveltime="66.18" overlapTraveltime="66.43" density="0.57" laneDensity="0.29" occupancy="0.13" waitingTime="0.00" timeLoss="0.42" speed="4.59" speedRelative="0.33" departed="0" arrived="0" entered="0" left="1" laneChangedFrom="0" laneChangedTo="0"/>
<edge id="e3" sampledSeconds="85.88" traveltime="87.35" overlapTraveltime="88.45" density="7.16" laneDensity="3.58" occupancy="1.78" waitingTime="0.00" timeLoss="7.23" speed="4.58" speedRelative="0.33" departed="0" arrived="0" entered="1" left="0" laneChangedFrom="0" laneChangedTo="0"/>
</interval>
<interval begin="270.00" end="300.00" id="dump_15">
<edge id="e3" sampledSeconds="59.00" traveltime="87.26" overlapTraveltime="88.37" density="4.92" laneDensity="2.46" occupancy="1.23" waitingTime="0.00" timeLoss="4.92" speed="4.58" speedRelative="0.33" departed="0" arrived="2" entered="0" left="0" laneChangedFrom="0" laneChangedTo="0"/>
</interval>
<interval begin="300.00" end="330.00" id="dump_15">
<edge id="e3" sampledSeconds="30.00" traveltime="87.10" overlapTraveltime="88.19" density="2.50" laneDensity="1.25" occupancy="0.63" waitingTime="0.00" timeLoss="2.45" speed="4.59" speedRelative="0.33" departed="0" arrived="0" entered="0" left="0" laneChangedFrom="0" laneChangedTo="0"/>
</interval>
<interval begin="330.00" end="332.00" id="dump_15">
<edge id="e3" sampledSeconds="2.00" traveltime="81.29" overlapTraveltime="82.41" density="2.50" laneDensity="1.25" occupancy="0.62" waitingTime="0.00" timeLoss="0.03" speed="4.91" speedRelative="0.35" departed="0" arrived="1" entered="0" left="0" laneChangedFrom="0" laneChangedTo="0"/>
</interval>
</meandata>
```

Attachment: DensityVsTime Loss.png
Description: PNG image