Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [sumo-user] No of vehicle passing through a detector using TRACI
  • From: <Maria.Armellini@xxxxxx>
  • Date: Tue, 14 Jul 2020 08:39:18 +0000
  • Accept-language: de-DE, en-US
  • Delivered-to: sumo-user@xxxxxxxxxxx
  • Ironport-phdr: 9a23:u+eiwxAUhj3bGok1/1x2UyQJP3N1i/DPJgcQr6AfoPdwSP37ps2wAkXT6L1XgUPTWs2DsrQY0rSQ6PirATFIyK3CmUhKSIZLWR4BhJdetC0bK+nBN3fGKuX3ZTcxBsVIWQwt1Xi6NU9IBJS2PAWK8TW94jEIBxrwKxd+KPjrFY7OlcS30P2594HObwlSizexfLJ/IA+4oAnNucUanYtvIbstxxXUpXdFZ/5Yzn5yK1KJmBb86Maw/Jp9/ClVpvks6c1OX7jkcqohVbBXAygoPG4z5M3wqBnMVhCP6WcGUmUXiRVHHQ7I5wznU5jrsyv6su192DSGPcDzULs5Vyiu47ttRRT1jioMKjw3/3zNisFojKxVvg+vpwBxzYDXboGaNvt+cb/Sc9wVXmdBQt9RVy5dDo+gc4cDEewMNvtYoYnnoFsOqAOzCA6rCuz10D9Ih2X50bcm3uQ7FAHJwgggH9YPsHTSrdX4L7odUeSvzKXS0DrMcepb1DHg44fHbh4vu+uDXa5sccXP00kvERvIgFuQpID7MD6Y1PgAv3af4udgWu+iiXIrpgVxrzWvx8ohlInHi4EIx13K9yh13YY7KNmkRENmf9OpHoVcuiCaOYZwX8gsTWZouCMgxb0Hv562ZC4Kx448yBHEb/yIbZKE7Q7kVOaUOTt3mm5qeLa+hxaq6kiv1PfwVs6u0FZFqCdOj9rCtmgV2hDO9sSLUOZx80Su1DqVygze5OJJLVoqmabFM5It37w9moQJvUjdAyP6glj6ga2Xe0k+5+Sl7fnsbK/8qZ+GLYB0jxnzMqEpmsOiH+s1KhMOX22H+eSk073j4FH5TK1KjvIolqnZt4jXK8odqKC3DAFb0oYt5RG8ATmhytoUg2cLIl1Edx+ZlYTpOlfOIOziDfilmVijjTNrx+rcMrL8HJrBNnnDkLH/crZh80NQ1RY/wcpC659XBbwNOu//V0HyudDCEBM1LRS4w+P9B9V80oMeV3iPAqicMK7KtlGH/PgvI+iWa4MPpDv9Mf0l6ODqjX89mF8de6ip0IAKZ3C8BPRqOViWbmT0jtcbDWgKphY+TPDtiFCaSj5TenOyX6Ul6jEmE4KpE53DS5uzj7Od2Ce7H4VWZntYBVyWFnfobYqECL8xbjmPKJphjiAcTurmDJA+ylejvwv706FqaO3O9WodvJPn0dFzoOnSjg0z8zJzSN+A1mbIUnp5hDA1QSQr1pxysVAoykufybMqxLtHCsMV6vhNUx8hONjb1eM9DtnzXgfIeJCNSU26Q9OoBnYqU9c2hsIVblwuJ9L32gve2i3vHqQYjZSGD5g16rnRmX/rKJAu5WzB0fx1qlA8Q8IJHHeji6p79g7SL4LNiQOVmvD5JuwnwCfR+TLbniK1t0ZCXVsoXA==
  • Ironport-sdr: J54YBJTSkyNrk821/yeVHD0OD2ThfB4xsi0lt/9UqWnPWNbcNlm675Cda6LPMBTQ6kBambkPUX 4WGKHFwWbN6w==
  • List-archive: <https://www.eclipse.org/mailman/private/sumo-user>
  • List-help: <mailto:sumo-user-request@eclipse.org?subject=help>
  • List-subscribe: <https://www.eclipse.org/mailman/listinfo/sumo-user>, <mailto:sumo-user-request@eclipse.org?subject=subscribe>
  • List-unsubscribe: <https://www.eclipse.org/mailman/options/sumo-user>, <mailto:sumo-user-request@eclipse.org?subject=unsubscribe>
  • Thread-index: AQHWWVLSoLSGzKPqU0OclOUsNN3mUKkGrUqA///oMoCAACYKEA==
  • Thread-topic: [sumo-user] No of vehicle passing through a detector using TRACI

Hi Anil,

did you check the detectors output file?
Have you defined the induction loops in an xml file and added it to your simulation? In this file you have to define an output file for each detector. In this case it will be "out.xml".

<additional>
  <inductionLoop id="myLoop1" lane="foo_0" pos="42" freq="900" file="out.xml"/>
  <inductionLoop id="myLoop2" lane="foo_2" pos="42" freq="900" file="out.xml"/>
  ....
</additional>

When you start the simulation, this file will be created and all parameters for each detector and time interval will be saved. The number of vehicles passing through the detector is in "nVehEntered".
Although the frequency and file attributes, as the documentation says, do not matter for TraCI, both attributes are important if you want to get information from the whole simulation.

The getLastStepVehicleNumber in TraCI only return the number of vehicles that were on the named induction loop within the last simulation step.

Regards,
Giuliana


-----Original Message-----
From: sumo-user-bounces@xxxxxxxxxxx [mailto:sumo-user-bounces@xxxxxxxxxxx] On Behalf Of anilbaral
Sent: Dienstag, 14. Juli 2020 10:00
To: sumo-user@xxxxxxxxxxx
Subject: Re: [sumo-user] No of vehicle passing through a detector using TRACI

Hi Maria, 
Thanks for the reply. Well, I have tried to use the induction loop
detectors; however, I could only obtain a vehicle for the last time step. I
couldn't obtain the number of vehicle in certain time interval. 
The command getLastStepVehicleNumber only gives me number of vehicle passing
through the induction loop detectors in last time step of 1sec. I want to
get the number of vehicle passing through the entire simulation time, which
is 3000 sec. 

Thanks, 
Anil 



--
Sent from: http://sumo-user-mailing-list.90755.n8.nabble.com/
_______________________________________________
sumo-user mailing list
sumo-user@xxxxxxxxxxx
To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/sumo-user


Back to the top