HIGHWAY ACCIDENT RISK PREDICTION AND BLACKSPOT DETECTION USING MACHINE LEARNING | IJET Volume 12 – Issue 5 | IJET-V12I5P28

IJET
International Journal of Engineering and Techniques
ISSN 2395-1303 · Peer-Reviewed · Open Access
📚 Volume 12, Issue 5
📅 September 22, 2026
📄 Pages 255–264
🔖 ID: IJET-V12I5P28

HIGHWAY ACCIDENT RISK PREDICTION AND BLACKSPOT DETECTION USING MACHINE LEARNING

Author(s)

Dungavath Dushyanth Naik, Dr. S. Swarnalatha

Abstract

Road traffic accidents continue to be one of the greatest challenges to highway safety, and there is a need for proactive approaches that can be used to identify locations where accidents are likely to occur and to predict accident risk. In this study, an integrated framework for highway accident risk prediction and blackspot detection is presented by applying machine learning with spatial analysis and supervised learning. The haversine distance metric is used for DBSCAN to detect spatial concentration of accidents in blackspots. Kernel Density Estimation (KDE) is used to visualise a continuous representation of the accident-density pattern. Random Forest (RF) and Extreme Gradient Boosting (XGBoost) classifiers are used to predict the risk and are evaluated by accuracy, precision, recall, F1-score and AUC-ROC. In the principal model evaluation reported in the study, XGBoost obtained 91.2% accuracy, 90.5% precision, 89.8% recall, 90.1% F1-score and 0.947 AUC-ROC, while Random Forest got 89.4% accuracy. The DBSCAN algorithm found 14 clusters corresponding to highway black spots with an optimised epsilon value of 1.0 km and a minimum of 5 samples, and a silhouette score of 0.58.

Keywords

Highway safety; Accident risk prediction; Blackspot detection; DBSCAN; Kernel Density Estimation; Random Forest; XGBoost; Machine learning; Spatial analysis; Streamlit

Conclusion

1.For the selected parameters (ε = 1.0 km and MinPts = 5), DBSCAN was able to detect 14 concentrated highway accident clusters.
2.Accident-density assessment: In addition to the output of DBSCAN, KDE also produced a continuous surface of accident density.
3.Risk-prediction performance: The comparative evaluation revealed that the model with the best performance was XGBoost, with a score of 91.2% accuracy, 90.5% precision, 89.8% recall, 90.1% F1-score and 0.947 AUC-ROC.
4.The top four variables in the XGBoost feature-importance analysis were speed (34.2%), accident density (22.8%), road type (14.6%), and blackspot severity (12.3%).
5.Operational risk advisory: The developed safe-speed module was able to identify high predicted risk and then incorporate actionable recommendations for a speed reduction by an iteration of 5 km/h.
6.Finally, the last Streamlit implementation showed the integration of the data processing, the blackspot detection, the KDE mapping, the evaluation of the machine-learning models, the feature-importance analysis, the prediction of the risk in real time, and the calculation of the safe speed in a single platform.

References

[1]Anderson, T.K. (2009). Kernel density estimation and K-means clustering to profile road accident hotspots. Accident Analysis & Prevention, 41(3), 359–364.
[2]Ahmadi, N., Ataei, S.M.-N., Khosravi, S., Jafari, A., Shahraz, S. & Farzadfar, F. (2025). Interpretable machine learning models to predict errors in road accident hotspots using telematics data. PLOS ONE, 20(7), e0326483.
[3]Breiman, L. (2001). Random forests. Machine Learning, 45(1), 5–32.
[4]Chen, T. & Guestrin, C. (2016). XGBoost: A scalable tree boosting system. In Proceedings of the 22nd ACM SIGKDD International Conference on Knowledge Discovery and Data Mining, 785–794.
[5]Ester, M., Kriegel, H.-P., Sander, J. & Xu, X. (1996). A density-based algorithm for discovering clusters in large spatial databases with noise. In Proceedings of the Second International Conference on Knowledge Discovery and Data Mining, 226–231.
[6]Santos, D., Saias, J., Quaresma, P. & Nogueira, V.B. (2021). Machine learning approaches to traffic accident analysis and hotspot prediction. Computers, 10(12), 157.
[7]Khanum, H., Garg, A. & Faheem, M.I. (2023). Accident severity prediction on Indian highways using Random Forest. F1000Research, 12, 494.
[8]Bokaba, T., Doorsamy, W. & Paul, B.S. (2022). Comparative study of machine learning classifiers for modelling road traffic accidents. Applied Sciences, 12(2), 828.
[9]AlMamlook, R.E., Kwayu, K.M., Alkasisbeh, M.R. & Frefer, A.A. (2019). Comparison of machine learning algorithms for predicting traffic accident severity. In 2019 IEEE Jordan International Joint Conference on Electrical Engineering and Information Technology (JEEIT).
[10]Zangeneh, A., Najafi, F., Karimi, S., Saeidi, S. & Izadi, N. (2018). Spatial-temporal cluster analysis of mortality from road traffic injuries using geographic information systems in the west of Iran during 2009–2014. Journal of Forensic and Legal Medicine, 55, 15–22.
[11]Kaygisiz, Ö., Düzgün, Ş., Yildiz, A. & Senbil, M. (2015). Spatio-temporal accident analysis for accident prevention in relation to behavioural factors in driving: The case of South Anatolian Motorway. Transportation Research Part F: Traffic Psychology and Behaviour, 33, 128–140.
[12]Hamdar, S.H., Qin, L. & Talebpour, A. (2016). Weather and road geometry impact on longitudinal driving behaviour: Exploratory analysis using an empirically supported acceleration modelling framework. Transportation Research Part C: Emerging Technologies, 67, 193–213.
[13]Khan, M.Q. & Lee, S. (2019). A comprehensive survey of driving monitoring and assistance systems. Sensors, 19(11), 2574.
[14]Siami, M., Naderpour, M. & Lu, J. (2021). A mobile telematics pattern recognition framework for driving behaviour extraction. IEEE Transactions on Intelligent Transportation Systems, 22(3), 1459–1472.
[15]Pedregosa, F., Varoquaux, G., Gramfort, A. et al. (2011). Scikit-learn: Machine learning in Python. Journal of Machine Learning Research, 12, 2825–2830.

📋 How to Cite This Paper

Dungavath Dushyanth Naik, Dr. S. Swarnalatha (2026). HIGHWAY ACCIDENT RISK PREDICTION AND BLACKSPOT DETECTION USING MACHINE LEARNING. International Journal of Engineering and Techniques, 12(5), 255–264. ISSN: 2395-1303. DOI: https://doi.org/10.5281/zenodo.22901734
© 2026 International Journal of Engineering and Techniques (IJET). All rights reserved. · ijetjournal.org

Submit Your Paper