Jam at the junction - can you beat the queues and get the cars past the traffic lights faster than everyone else? Interactive traffic simulation for all ages.
An open source traffic light control game for engagement events with potential for crowd sourcing data. See it in action on YouTube
INSTALLATION GUIDE: READ HERE.
Please acknowledge the author and other relevant contributors in any derivative works. Not for commercial use.
Copyright 2017: Craig B. Rafter
Distributed under GNU GPL-3.0
A simple crossroads simulated using the TraCI Python API to the SUMO microsimulator. The program maps the keyboard arrow keys to control the direction of the traffic flow using the Pynput Python library. The sumoAPI included is from the Traffic Control Test Set.
The simulation is capable of storing the results localy and diplaying them on a web page. Or posting the results online to Twitter using the Python Twitter API. The user defined names are limited to 4 characters and filtered for profanity. A separate server scipt is provided to update the results from the twitter feed periodically. Users will need to provide their own twitter API crednetials in twitAuth.py
The background was created using GIMP, art credits below. Given the intention of displaying this to a wide audience, the vehicles are colored in a color blind accessible color palette. See (B. Wong, 2011) for details of the color palette.
- Log user data so that machine learning can be applied to good user scores.
- Make a two-player junction for cooperative play.
System built and tested on:
- Ubuntu 16.04.1 LTS
- SUMO 0.29.0
- Python 2.7
- Pynput 1.2
- Python Profanity 1.1
- Python Twitter 3.2.1
Trees:
Buildings:
- User "JSena" PixelJoint
- User "duyvi" PixelJoint
- User "Matriax" PixelJoint
Wong, B. "Points of view: Color blindness", Nature Methods, 8, 441, 2011, doi:10.1038/nmeth.1618