Traffic Signal Management using Machine Learning Algorithm

DOI : 10.17577/IJERTV9IS060198

Download Full-Text PDF Cite this Publication

Text Only Version

Traffic Signal Management using Machine Learning Algorithm

Prof . Sunayana Jadhav#1 , Siddharth Vaghela, Shubham Tawde, Rashmi Bharambe, Stuti Mangalvedhe,

K.J Somaiya College of Engineering, Department of Information Technology, Vidyavihar. Mumbai 77

Abstract Traffic clog is one of the significant issues in India and it is particularly prevalent in the metropolitan urban areas of the nation. Clogged streets can be viewed for instance of the awfulness of the lodge. Since streets in many spots are free at the purpose of use, there is minimal money related motivation for drivers not to over-use them, up to where traffic falls into a jam, whenever request gets constrained by circumstance cost. Privatization of interstates and street estimating have both been proposed as measures that may decrease clog through monetary motivating forces and disincentives. Blockage can likewise occur due to non-repeating parkway occurrences, for example, an accident or roadworks, which may lessen the street's ability underneath ordinary levels.While clog is a likelihood for any method of transportation, greater part of the systems included spotlight on car blockage on open streets. Image processing techniques have been generally utilized in the control and the executives of traffic frameworks. To evacuate the extravagance and infeasibility of these picture preparing frameworks, this paper proposes an elective methodology, an algorithm, that would help circulate the traffic equitably whilst controlling the signal by utilizing HERE maps API.

Index terms- Traffic control, traffic clog, congestion, api, traffic signal algorithm, machine learning.


    India gloats of being the second-biggest street organize on earth. The complete stretch of the Indian street systems remain at an astounding 5.4 million km! Thus, it shapes a gigantic final proposal for the Indian Government to give impeccable streets at each progression. For any Indian, be it normal or millennial, passing through the Indian lanes is absolutely an issue that no might want to experience. As request moves toward the limit of a street (or of the convergences along the street), outrageous traffic blockage sets in. At the point when vehicles are completely halted for timeframes, this is known as a traffic jam or (casually) a traffic growl up. Traffic blockage can prompt drivers getting baffled and participating in street rage.

    Numerically, clog is normally taken a gander at as the quantity of vehicles that go through a point in a window of time, or a stream. A portion of the standard traffic issues incorporate

    • Poor street quality because of over the top traffic-The outrageous clog of urban streets because of intensely utilized

      private vehicles prompts the corruption of the nature of the streets. This prompts ceaseless traffic issues more often than not.

    • Noise and Air pollution especially in urban areas- The sheer magnitude of traffic problems also gives rise to other health-damaging issues such as the air and sound pollution.

    So, we propose a solution which controls the traffic dynamically based on various important factors like time of day, climate, condition of roads etc. The system enables to distribute the traffic congestion evenly throughout the area.


Adaptive signal control system were implemented using deep learning and reinforcement learning algorithm (RL). Instead of a real traffic operation, the present study utilized Vissim, a commercial traffic simulator, as an environment. A real intersection located in Seoul, Korea was chosen as a test- bed for the simulation. that showed both a real photo and an animation image of the test-bed.[1]

Complex backgrounds should be eliminated from real photos prior to being inputted for the CNN model. Simple image-processing skills can accommodate this process when adopting real photos in the future. The algorithm was trained for 20,000 simulation seconds (= about 5 hours 30 minutes) for each episode. There were 50 episodes simulated for training the model. Thus, the total simulation time was tantamount to 1,000,000 seconds. [1]

Another project that was acted upon was one based on google map java app which used data from google maps. Google maps provide real time traffic density.The core of the idea lies on Image Processing of the already existing Traffic API provided by Google. Google Traffic API provides the real-time data of the traffic conditions for any given coordinates, which gives color-coded traffic density data, which can be further processed to analyze the traffic flow at a given traffic junction and hence, the traffic lights can be dynamically controlled to regulate the traffic.[6]

This system works to make sure that there is not an uneven distribution of Wait Time and therefore uneven accumulation of traffic at a junction.[6]

Another real-time traffic-adaptive signal control system referred to as RHODES[12] was also taken into consideration. The system takes as input detector data for real-time measurement of traffic flow, and optimally controls the flow through the network. The system utilizes a control architecture that (1) decomposes the traffic control problem into several

subproblems that are interconnected in an hierarchical fashion,

  1. predicts traffic flows at appropriate resolution levels (individual vehicles and platoons) to enable pro-active control,

  2. allows various optimization modules for solving the hierarchical subproblems, and (4) utilizes a data structure and computer/communication approaches that allow for fast solution of the subproblems, so that each decision can be downloaded in the field appropriately within the given rolling time horizon of the corresponding subproblem.


The basis for our proposed solution proceeds as follows-

The HERE maps API enables us to extract the traffic density of a particular road. API provides us with jam factor of particular road. The extraction of API from maps leads us to the lane where we want to check congestion.

After extracting the API, we check the congestion of vehicles. The congestion tends to be more in bottleneck areas. Also, we check the surrounding roads as well to distribute the congestion from one crowded road to less crowded ones.

\According to the best factor which can be chosen at that time, the system selects it. The priority list will be set in it. The system will execute the algorithm and dynamically handle the traffic density.

If one lane has much less traffic than the other, half of the traffic will be diverted to the other empty lanes and the density will be distributed accordingly throughout the area.


The proposed framework means to progressively change the hour of the traffic signal in view of a predetermined objective to lessen the blockage of traffic out and about thus diminishing the time an individual needs to hold up in rush hour gridlock. The framework depends on AI calculation which will push us to progressively change the hour of the traffic signal. The framework will show the recreation of the traffic clog changing persistently dependent on the dynamic time that is being given to the traffic signal dependent on noteworthy forecasts of traffic on that street

Product functions and features-

Initially, data preprocessing was performed by storing only those attributes(obtained from the api) that were prescriptory for further implementation of our model. Also, the immediate and vital preprocessing gait which is data cleaning was prformed by getting rid of inconsistent values such as empty strings and zero-based values. The dynamic of our model would then function as follows-

1 After the user ingresses the coordinates of the junction, the website would extract details of the particular junction using HERE Maps api. These details are primarily provided in the JSON(JavaScript Object Notation) format.

  1. These details include the average speed of the vehicle, length of the road, the maximum speed of any vehicle on the road and the jam factor (i.e traffic density) on that particular stretch of road.

  2. The distinct value proposition of the product would lie in the data which would be defined accordingly, as per the assumed direction of the traffic. This defined data would be segregated into multiple classes.

  3. Using the self-implemented algorithm, the basis of which would lie in Naive Bayes, the traffic would get distributed to the surrounding lanes based on the threshold of the jam factor. This area would help us decide the number of vehicles extant for a given time.

  4. The timer of the signal would be handled by calculating the amount of time required for a vehicle to pass which would ultimately depend on the area of the particular junction.

5. The output for the same would be demonstrated using a simulation of the junction.

Hardware Interfaces include-

Devices that support web browsers such as PC, laptops and handheld devices.

Software Interfaces include-

The GUI that we will utilize is PyCharm which is a Python IDE used to compose and investigate Python code

  • To spare the information for preparing the model, we will utilize MySQL Database

  • The Graphical User Interface (GUI) execution will be done in Django.

  • We have picked Windows as our Operating System for improvement for its best help and ease of use.

User interface

The Adaptive Traffic Control System screen displays shall conform to the Process Impact Internet Application User Interface Standard, Version 2.0. The Web pages shall permit complete navigation and data selection and display using the keyboard alone, in addition to using mouse and keyboard combinations.


To execute our objectives and targets we first concentrate information from HERE Maps API, which gives us the traffic density information as JSON or XML position. We get different highlights with respect to the traffic out and about, for example, the normal speed of any vehicle on that specific street, the length of the street, the most extreme speed of any vehicle out and about and the jam factor (the traffic density) on that stretch of street.

Our underlying advance was to arrange our condition for information assortment from the API and putting it into the database. During the assortment of information, we pre- handled information, putting away just the traits that were required for additional execution of our model. We even performed cleaning of the information to dispose of conflicting information, for example, zero qualities.

To quantify the proficiency of our framework, regardless of whether we have figured out how to decrease the traffic clog on the streets utilizing our mimicked model, we will contrast our reproduced qualities and the constant qualities got from the API. We will quantify the distinction between these qualities, and this distinction when communicated as far as rate will characterize how better traffic can be overseen/controlled utilizing our actualized model.


Thus, our fundamental aim is to control the traffic flags powerfully dependent on the present traffic density and considering the memorable traffic density esteems. Among the streets that we have considered, the street having the most noteworthy jam factor (traffic density) will be viewed as first and in our recreation run the jam factor will be decreased dependent on the surmised normal speed of any vehicle on that specific street and the traffic on the ensuing street. Time for a specific activity, ie, a red light or a green light will be given dependent on different elements, basically the jam factor.

Accordingly, with the expanding traffic in our everyday life, the need to oversee it has become a need now

Our model gives an ideal answer for the intersections at top occasions just as different occasions. In this venture, we have

proposed a strategy to forestall blockage of traffic by wiping out the customary picture handling technique utilized by the past frameworks and by controlling the traffic lights powerfully.


This research was supported by Department of Information Technology K.J Somaiya College of Engineering.


  1. Julian Nubert, Nicholas Giai Truong, Abel Lim, Herbert Ilhan Tanujaya, Leah Lim, Mai Anh Vu, Traffic Density Estimation using a Convolutional Neural Network Machine Learning Project, National University of Singapore, 5 September 2018

  2. M Bando, K Hasebe, A Nakayama, A Shibata, Dynamical model of traffic congestion and numerical simulation, Phys. Rev. E 51, 1035, 1 February 1995

  3. M Luo, SC Lin, IF Akyildiz, Software defined network traffic congestion control, Scientific Programming Volume 2017, Article ID 3579540, December 2017

  4. Q Wang, J Wan, Y Yuan, Locality constraint distance metric learning for traffic congestion Pitu, Larry Head, A real-time traffic signal control system: architecture, algorithms, and analysis.

  5. Eigen, D., and Fergus, R. 2014. Predicting depth, surface normals and semantic labels with a common multi-scale convolutional architecture. CoRR abs/1411.4734.

  6. Assessment of network traffic congestion through Traffic Congestability Value (TCV): a new index Nilanchal Patel, CFMR, Alok Bhushan Mukherjee,2015.

  7. Gao, J.; Shen, Y.; Liu, J.; Ito, M.; and Shiratori, N. 2017. Adaptive traffic signal control: Deep reinforcement learning algorithm with experience replay and target network. CoRR abs/1705.02755.

  8. Goodfellow, I.; Bengio, Y.; and Courville, A. 2016. Deep Learning. MIT Press.

  9. Singh, L.; Tripathi, S.; and Arora, H. 2009. Time optimization for traffic signal control using genetic algorithm. 2.

  10. Szegedy, C.; Vanhoucke, V.; Ioffe, S.; Shlens, J.; and Wojna, Z. 2016. Rethinking the inception architecture for computer vision.

  11. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 28182826.

  12. RHODES to Intelligent Transportation Systems Pitu Mirchandani, University of Arizona,2005.

  13. Fei-Yue Wang, University of Arizona and Chinese Academy of Science

  14. Wong, S. C.; Gatt, A.; Stamatescu, V.; and McDonnell, M. D. 2016. Understanding data augmentation for classification: When to warp?

  15. 2016 International Conference on Digital Image Computing: Techniques and Applications (DICTA) 16.

  16. Yosinski, J.; Clune, J.; Bengio, Y.; and Lipson, H. 2014. How transferable are features in deep neural networks? In Advances in neural information processing systems, 33203328.

  17. C. P. Fu and S. C. Liew, TCP Veno: TCP enhancement for transmission over wireless access networks, IEEE Journal on Selected Areas in Communications, vol. 21, no. 2, pp. 216228, 2003.

  18. C. Caini and R. Firrincieli, TCP Hybla: A TCP enhancement for heterogeneous networks, International Journal of Satellite Communications and Networking, vol. 22, no. 5, pp. 547566, 2004.

  19. C. E. Palazzi, M. Brunati, and M. Roccetti, An OpenWRT solution for future wireless homes, in Proceedings of the 2010 IEEE International Conference on Multimedia and Expo, ICME 2010, pp. 17011706, July 2010.

  20. D. SreeArthi, S. Malini, M. J. Jude, and V. C. Diniesh, Micro level analysis of TCP congestion control algorithm in multi-hop wireless networks, in roceedings of the 2017 International Conference on Computer Communication and Informatics (ICCCI), pp. 15, January 2017.

  21. B.-J. Chang, Y.-H. Liang, and J.-Y. Jin, Adaptive cross-layer-based TCP congestion control for 4G wireless mobile cloud access, in Proceedings of the 3rd IEEE International Conference on Consumer Electronics-Taiwan, ICCE-TW 2016, pp. 1-2, May 2016.

  22. M. Claeys, N. Bouten, D. De Vleeschauwer et al., Deadline-aware TCP congestion control for video streaming services, in Proceedings of the 12th International Conference on Network and Service Management, pp. 100108, November 2016.

  23. J. Gruen, M. Karl, and T. Herfet, Network supported congestion avoidance in software-defined networks, in Proceedings of the 2013 19th IEEE International Conference on Networks, ICON 2013, p. 16, December 2013.

  24. J.-H. Wang, K. Ren, W.-G. Sun, L. Zhao, H.-S. Zhong, and K. Xu, Effects of iodinated contrast agents on renal oxygenation level determined by blood oxygenation level dependent magnetic resonance imaging in rabbit models of type 1 and type 2 diabetic nephropathy, BMC Nephrology, vol. 15, no. 1, article 140, 2014.

  25. Gartner Identifies the Top 10 Strategic Technology Trends for 2015, 2014,

  26. P. Sun, M. Yu, M. J. Freedman, J. Rexford, and D. Walker, HONE: Joint Host-Network Traffic Management in Software-Defined Networks, Journal of Network and Systems Management, vol. 23, no. 2, pp. 374399, 2015.

  27. H. Long, Y. Shen, M. Guo, and F. Tang, LABERIO: dynamic load- balanced routing in OpenFlow-enabled networks, in Proceedings of the IEEE International Conference on Advanced Information Networking Applications, pp. 290297, 2013.

  28. L. Lu, Y. Xiao, and H. Du, OpenFlow control for cooperating AQM scheme, in Proceedings of the 2010 IEEE 10th International Conference on Signal Processing, ICSP2010, pp. 25602563, October 2010.

Leave a Reply