Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [sumo-user] Request for Traffic Signal Position and State Information in SUMO

You may use the tool https://sumo.dlr.de/docs/Tools/Net.html#net2geojsonpy
with option --traffic-lights to obtain the shapes of the red/green/yellow bars along with their associated trafficLight ID and signal index
To obtain states at runtime, see https://sumo.dlr.de/pydoc/traci._trafficlight.html#TrafficLightDomain-getRedYellowGreenState or (the signal index corresponds to the position in the returned state string).

Am Di., 20. Mai 2025 um 14:09 Uhr schrieb Manohara C V via sumo-user <sumo-user@xxxxxxxxxxx>:
Dear SUMO Team,
I am currently working on a  integration project and would like to retrieve the exact physical positions of traffic signals corresponding to indices 0, 1, 2, and 3 within a TLS (traffic light system), rather than referring only to the common tls_id.
Could you please guide me on how to obtain the positional coordinates of these individual signals? Additionally, I would like to extract their associated state values (e.g., red, yellow, green) during the simulation for visualization purposes.
If there is any documentation or article that already covers this, I would appreciate it if you could share the reference.


traci_tutorial_tls.png

Thanks & Regards,

Manohara C V

AI Services 

image

_______________________________________________
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