# Introduction ccording to ((K.N.B.S), 2017) road traffic accident statistical abstracts,3000 persons die while approximately 14,000 persons are injured annually due to RTAs. The vehicles involved on RTAs are approximately 9,000. The levels of disability caused by RTAs are on rise. Economically Kenya incurs a loss of approximately US$50 million annually according to (Mutune Peter Kasau, Prof. Eng. G. N. Mang'uriu, Dr. Stephen Diang'a, 2017), due to RTAs. in all PSV's and commercial vehicles whose weight limit should not exceed the 3,048 kilograms, speed limit of 80 kilometers per hour, fitting of seat belts on all vehicles, employment of drivers and conductors on permanent basis, indication of route details and painting of a yellow band on Matatus (a passenger Vehicle) for purposes of easy identification, re-testing of drivers after every two years and approval of all driver's identification by the police and also ban on night travelling. It also launched a six-month Road Safety Campaign in 2003 and declared war on corruption, which contributes and indirectly to the country's unacceptably high levels of RTAs. These policies failed to deliver the expected results which compelled the government to resort to intermitted crackdown on the public service vehicles in an attempt to reduce the RTAs. The crackdown increased the level of corruption which led to increased RTAs. The traffic act was amended to introduce the safety belt and blood alcohol level laws. The aim was to enhance the safety of passengers and ensure the drivers were always sober while driving. The inspection of road vehicles was also introduced. The government enacted the National Transport Safety Authority (NTSA) Act in 2012.The NTSA was mandated to ensure the safety of the roads was enhanced and managed well. This was to be achieved through registration road vehicles, licensing of drivers, testing the drivers, regulating the driving schools and also conducting research on road safety to provide the advice to the government on the RTS policies and also implementing of road safety policies. Under the NTSA people are still losing lives, the properties destroyed due to RTAs. This is attributed to the implementations of policies which are not informed by a scientific research. An accurately classification of RTSS of inside the vehicle conditions using the artificial neural network can ultimately enhance the RTS and prevent the loss of human lives. By knowing the current safety state of vehicle, the necessary precautions can then be taken in advance to prevent an occurrence of RTA. According to (Maja Urosevic,2018), the trained neural network is an expert in the category of information it has been given to analyze, this expert can then be used to classify the RTSS of vehicle dynamically and give alerts in real time averting an impending occurrence of RTA in case of poor or danger safety state of vehicle. According to (Antonio Celesti, Antonino Galletta, Lorenzo Carnevale, Maria Fazio, Aime Lay-Ekuakille and Massimo Villar), Year 2 019 ( ) D © 2019 Global Journals Enhancing Road Traffic Safety in-Kenya using Artificial Neural Networks modern vehicles have inbuilt sensors, control devices and micro-controller chips. By leveraging this emerging technologies in automobile industry compounded by the artificial neural network as the expert while sensors as input devices and control devices as RTS regulator, the RTA can be reduced. In this study we applied a multi-layer perceptron feed-forward trained neural network with forty three selected input variables to model and to classify RTSS outcomes to determine the safety state of vehicle to inform the RTS vehicular policies and decisions in Kenya. The purpose of this study was to examine patterns of vehicular accidents, design and develop a neural network model and evaluate the model performance on classifying RTSS. # II. # Materials/Tools Materials used in study were data, statistical programming software i.e. R, database management system i.e. Oracle Database, Neural Network Framework i.e. Neuroph Studio. # a) Data Requirements In this research data was collected from RTAs Reports from NTSA daily and fatal reports and KNBS statistical abstracts. This data is readily available in websites. The categorical data was collected from experts in RTSA which included:-traffic police, NTSA, drivers, St John's ambulance and the public via guided questionnaires. We primarily considered the factors that contributed to RTAs as models inputs and RTS status as model's output as shown in This was due to their easy to handle aspect by the riders making them ideal for busy towns to ease traffic congestion. # The Neural Network Model for Enhancing Road Traffic Safety In this research we utilized a multi-layer neural network with one hidden layer of neurons. After preprocessing of classical data, there were 43 model inputs and 4 model outputs. The classical data was converted into binary number format as shown in Table 1 in # Evaluation of Neural Network Architectures The training data set was divided into 70% training, 15% testing and 15% validation to facilitate neural network model development, experimentation and performance assessment. The results of Evaluation of various neural network architectures are shown in Table 2 in the appendices. The best neural network architecture was Backpropagation, Momentum 0.7, Maximum error 0.01, learning rate 0.5, number of epochs 1, had a MSE 000166.The Resilient Backpropagation and Dynamic Backpropagation were not able to learn. The overall classification accuracy for the best model was 76.0%, it had the precision of 1.0, and the recall of 0.7666666666666667 as shown in Fig 8. # Conclusion In this research we employed a multi-layer feedforward neural network with backpropagation learning rule to classify the Road Traffic Safety Status of Vehicle based on vehicle internal factors that contributed to RTAs. The model was trained, tested, and validated using 20,000data samples compiled from categorical data collected from experts in RTSA which included:traffic police, NTSA, drivers, St John's ambulance and the public via guided questionnaires. Forty three input variables consist of categorical data elements including: inside-vehicle-condition, entertainment, safetyawareness, passager's (attention, criminal-history, health-history, movement-inside-vehicle, body-posture, frequency-of-journey, drunkenness', drug-influence, use-of-mobile-phone and load), luggage-type and the safety-belt. These inputs and the multi-layer neural network model were used to classify road traffic safety state as: excellent, fair, poor or danger state. The multilayer perceptron feed forward neural network model with one hidden layer of fifteen neurons, variable learning rate of backpropagation, momentum value of 0.7, learning rate of 0.5 and weighted summation and sigmoid hidden activation functions achieved the best performance. The Resilient Backpropagation and Dynamic Backpropagation were not able to learn. Classification accuracy in most model architectures exceeded 74%. This model may be used to inform Road Traffic Safety policies and decisions. Model can be adopted in emerging vehicle automation technologies such as sensors, control devices, and micro controller chips as a safety measure hence saving loss of human lives on roads. # Appendices ![Fig.1](image-2.png "") 1![Fig. 1: The model's inputs, neural network and the outputs b) Data Pre -ProcessingThe data was cleaned by screening for errors and missing data elements. We deleted samples with missing data or errors. The most common error was blank spaces in questionnaires and in correct data format in NTSA Daily fatal reports. After cleaning the data set there were 1,000 data samples from NTSA daily and fatal reports and KNBS statistical abstracts and 20,000 data sample of classical data. The major data pre-processing task required prior to development, training and testing of the neural network models was the conversion of categorical variables to binary values. All the forty three input variables were categorical. To convert the categorical variables into binary representations requires transforming a categorical variable into an equivalent number of binary variables. Binary representation of categorical variables was chosen to facilitate future reduction of model variables while minimizing the impact on model structure.The pre-processed NTSA daily fatal road traffic reports and KNBS Road Traffic statistical abstracts data were uploaded into oracle Database for efficient data analysis as shown in Fig.2](image-3.png "Fig. 1 :") 2![Fig. 2: KNBS/NTSA RTAs data stored in an Oracle database 11g Express Edition c) Road Traffic Safety Patterns in Kenya The analysis tool applied in this paper is R which was connected to the oracle database 11g express edition as shown in the Fig 3.](image-4.png "Fig. 2 :") 3![Fig. 3: Illustrates how R Version 3.5.1 was connected to an oracle database 11g Express Edition The analysis of RTAs reports showed the following patterns: 1) According to ((K.N.B.S), 2017) road traffic accident statistical abstracts, the number of person who died per number of injured persons due to RTAs increased as shown in Fig 4.](image-5.png "Fig. 3 :") 4![Fig. 4: Number of Persons Killed per injury due to RTAs in Kenya This pattern was due to late reporting and response to incidences of RTAs. The poor handling of victims when freeing them from wreck and poor handling while transporting victims from scene of accident to hospital due to lack of rescue handling skills. The lack of specialized and functional equipment for diagnosing the internal injuries and extend of internal injuries. The late attendance to victims on arrival to hospital due to inadequate specialized medical personnel to attend injured victims. There was also lack of specialized expertise on trauma and accident victims. Lack of specialized technician to repair and maintain the specialized equipment. These factors have contributed to high rate of death of injured persons who could have been saved. 2) According to ((K.N.B.S), 2017) road traffic accident statistical abstracts, the pedal cycles are least involved in RTAs as shown in Fig 5.This was due to their easy to handle aspect by the riders making them ideal for busy towns to ease traffic congestion.](image-6.png "Fig. 4 :") 5![Fig. 5: Total number of vehicles involved in RTAs in Kenya 3) According to ((K.N.B.S), 2017) road traffic accident statistical abstracts, the general trend of RTS in Kenya increased as shown in Fig. 6, but there is need for further enhancement to save the 3000 lives which are lost annually and rescue the huge](image-7.png "Fig. 5 :") 6![Fig. 6: Trend of Road Traffic Safety in Kenya](image-8.png "Fig. 6 :") ![the appendices for use in neural network. The number of hidden neurons are varied from 8-35 while examining the impact on model performance. The weighted summation activation function was employed for the hidden layer while the sigmoid activation function was used for the outputs. Momentum values and learning rates are varied, examining the impact on model performance. Fig.7 below highlights the general neural network architecture. Several training algorithms were explored including learning rules:-Backpropagation with momentum, Backpropagation, Resilient Backpropagation and Dynamic Backpropagation. All Neural network architectures were developed utilizing neuroph studio a java Artificial Neural Network framework. The performance metrics used to evaluate the performance of the competing neural network architectures included-: MSE achieved, number of epochs, Momentum, Learning rate, Hidden Neurons, classification accuracy, recall, precision and training.](image-9.png "") 1No.VariableDescriptionData TypeLocationCodeWorse 1 0 0 01Inside vehicle conditionInside vehicle conditioncategoricalinputPoor Fair0 1 0 0 0 0 1 0Good0 0 0 1Low1 0 02EntertainmentEntertainmentcategoricalinputHigh0 1 0Excess high 0 0 13Safety awarenessSafety awareness inside vehiclecategoricalinputLack Few Many1 0 0 0 1 0 0 0 1Sleeping 1 0 04Passenger attentionPassenger attentioncategoricalinputDozing0 1 0Alert0 0 1Criminal history oflaw breaker1 0 05Criminal historypassengercategoricalinputever broken law0 1 0law abiding0 0 16Passenger health historyPassenger health historyCategoricalInputno health issue have health issue1 0 0 17Movement inside vehicleMovement inside vehiclecategoricalinputMinimal movement Much movement Excessive movement 0 0 1 1 0 0 0 1 08Body postureBody posturecategoricalinputImproper sitting position 1 0 Proper sitting 0 19Frequency of passenger journey ( ) D © 2019 Global Journals Enhancing Road Traffic Safety in-Kenya using Artificial Neural Networks * Analysis of Causes & Response Strategies of Road Traffic Accidents in Kenya ConsolataWangari Ndung'u, Ratemo MatayoBonface LydiaKMwai ISSN: 2319-7668 IOSR Journal of Business and Management IOSR-JBM) e-: 2278-487X 17 Apr. 2015 Issue 4.Ver. IV ( * Application of an Artificial neural Network to predict Graduation Success at the United States military Academy GeneLesinski StevenCorns CihanDagli 2016 * (K N B 2017 'Road traffic Accidents 2018' Road traffic injuries * Road Traffic Accidents Daily Reports 2018 * Lenses Classification using Neural Networks MajaUrosevic 2018 * An IoT Cloud System for Traffic Monitoring and Vehicular Accidents Prevention Based on Mobile Sensor Data Processing AntonioCelesti AntoninoGalletta LorenzoCarnevale MariaFazio AimeLay-Ekuakille MassimoVillari IEEE SENSORS JOURNAL 18 12 June 2018. JUNE 15. 2018 * FACTORS THAT INFLUENCE THE INCIDENCES OF ROAD ACCIDENTS IN KENYA: A SURVEY OF BLACK SPOTS ALONG MOMBASA-MALABA ROAD' -International Academic MutunePeter Kasau ProfG NEng DrStephenMang'uriu Diang Journal of Information Sciences and Project Management 2 1 2017