留言板

尊敬的读者、作者、审稿人, 关于本刊的投稿、审稿、编辑和出版的任何问题, 您可以本页添加留言。我们将尽快给您答复。谢谢您的支持!

姓名
邮箱
手机号码
标题
留言内容
验证码

基于BiLSTM神经网络的交通事故黑点路段日均事故频次预测方法

任毅 杨仁法 周继彪 胡正华 张敏捷

任毅, 杨仁法, 周继彪, 胡正华, 张敏捷. 基于BiLSTM神经网络的交通事故黑点路段日均事故频次预测方法[J]. 交通信息与安全, 2023, 41(2): 36-49. doi: 10.3963/j.jssn.1674-4861.2023.02.004
引用本文: 任毅, 杨仁法, 周继彪, 胡正华, 张敏捷. 基于BiLSTM神经网络的交通事故黑点路段日均事故频次预测方法[J]. 交通信息与安全, 2023, 41(2): 36-49. doi: 10.3963/j.jssn.1674-4861.2023.02.004
REN Yi, YANG Renfa, ZHOU Jibiao, HU Zhenghua, ZHANG Minjie. A Prediction Method of Daily Traffic Accident Frequency at Black Spots Based on Bi-Directional Long Short-term Memory Networks[J]. Journal of Transport Information and Safety, 2023, 41(2): 36-49. doi: 10.3963/j.jssn.1674-4861.2023.02.004
Citation: REN Yi, YANG Renfa, ZHOU Jibiao, HU Zhenghua, ZHANG Minjie. A Prediction Method of Daily Traffic Accident Frequency at Black Spots Based on Bi-Directional Long Short-term Memory Networks[J]. Journal of Transport Information and Safety, 2023, 41(2): 36-49. doi: 10.3963/j.jssn.1674-4861.2023.02.004

基于BiLSTM神经网络的交通事故黑点路段日均事故频次预测方法

doi: 10.3963/j.jssn.1674-4861.2023.02.004
基金项目: 

国家自然科学基金项目 52002282

浙江省哲学社会科学规划课题项目 21NDJC163YB

详细信息
    作者简介:

    任毅(1998—),硕士研究生. 研究方向:交通安全. E-mail:17671650795@163.com

    通讯作者:

    杨仁法(1967—),硕士,教授. 研究方向:交通运输规划与管理、区域发展等.E-mail:yang0403@163.com

  • 中图分类号: U491.31

A Prediction Method of Daily Traffic Accident Frequency at Black Spots Based on Bi-Directional Long Short-term Memory Networks

  • 摘要: 为交通管理部门和出行大众提供精准的事故高发黑点预警信息具有重要的意义。为此,研究了1种基于双向长短期记忆神经网络(bidirectional long short-term memory neural network,BiLSTM)的黑点路段交通事故频次预测方法。通过对传统K-means聚类算法的k值选取进行改进,实现了道路交通事故黑点的有效识别,并统计黑点每天事故数作为事故时间序列;利用小波分解对该序列进行降噪处理,通过多层网格搜索法对隐藏层层数、神经元个数等模型的参数进行标定,构建了基于BiLSTM网络的事故频次预测模型;采用滑动窗口的方式将事故时间序列作为内部参数输入模型,以交通流量、节假日、事故天气和事故发生环境等特征作为外部参数,对事故黑点路段未来1 d内可能发生的事故数进行预测,并基于预测结果提出了1种事故黑点路段交通事故预警模型;以浙江省宁波市交警部门某辖区2020年4月—2021年9月常态采集的事故数据为测试集,以7 d的事故数据预测未来1 d的黑点路段事故频次,将BiLSTM模型与门控循环神经网络(GRU)模型、长短期记忆神经网络(LSTM)模型、反向传播神经网络(BP)模型、自回归滑动平均(ARIMA)模型和支持向量机(SVR)模型等事故预测模型进行对比。结果表明:BiLSTM模型、GRU模型、LSTM模型、BP模型、ARIMA模型和SVR模型对各事故黑点的日均事故频次平均预测精度分别为93.1%、88.8%、88.0%、85.2%、84.4%和84.2%;均方根误差分别为0.092、0.146、0.142、0.147、0.177和0.176。该结果说明,所提BiLSTM模型具有更高的预测精度和更强的鲁棒性。

     

  • 图  1  事故点位分布

    Figure  1.  Accident points distribution

    图  2  事故类型

    Figure  2.  Accident type

    图  3  事故时间特征

    Figure  3.  Characteristics of accident week change

    图  4  事故小时变化特征

    Figure  4.  Characteristics of accidents hourly change

    图  5  事故黑点

    Figure  5.  Accident Black-spots

    图  6  LSTM细胞单元结构

    Figure  6.  Cell structure of LSTM

    图  7  BiLSTM网络结构

    Figure  7.  Network structure of BiLSTM

    图  8  实验事故黑点分布

    Figure  8.  Experimental accident black spots distribution

    图  9  降噪前后事故的时间序列数据

    Figure  9.  Time series of accidents before and after denoising

    图  10  各事故黑点交通流量时间序列数据

    Figure  10.  Time series of traffic flow at each accident black spot

    图  11  不同隐藏层层数下模型误差和训练耗时对比图

    Figure  11.  Comparison of model error and training time for different numbers of hidden layer

    图  12  不同的神经元个数下模型误差和训练耗时对比图

    Figure  12.  Comparison of model error and training time for different numbers of neuron

    图  13  不同批量下模型误差和训练耗时对比图

    Figure  13.  Comparison of model error and training time for different batch sizes

    图  14  基于BiLSTM的交通事故预测框架

    Figure  14.  Framework for accident prediction based on BiLSTM

    图  15  模型预测值与实际值对比

    Figure  15.  Comparison of predictions and ground truths

    图  16  不同模型预测精度及误差对比

    Figure  16.  Comparison of prediction accuracy and error by different models

    图  17  4种神经网络模型对各黑点交通事故预测精度箱型图

    Figure  17.  Box plot of traffic accident prediction accuracy of four neural network models for each black spot

    图  18  黑点交通事故预警箱型图

    Figure  18.  Box plot of black spot traffic accident early warning

    表  1  事故空间特征

    Table  1.   Spatial characteristics of accidents

    事故位置 事故比例/%
    路段 67.61
    交叉口 24.69
    小区/学校/医院/厂矿企业 5.37
    停车场 2.02
    桥梁 0.19
    高架 0.08
    匝道 0.04
    下载: 导出CSV

    表  2  事故严重程度

    Table  2.   Severity of accident

    事故形态 事故比例/%
    受伤 69.13
    物损 39.09
    死亡 0.78
    下载: 导出CSV

    表  3  实验黑点基本信息

    Table  3.   Basic information on experimental accident black spots

    黑点编号 黑点中心位置 黑点事故数/起
    1 广德湖北路与南环高架匝道入口交汇处 704
    2 中山东路与世纪大道交叉口 585
    3 中山东路与中兴路交叉口 451
    4 中兴南路与钱湖北路交汇处 354
    5 世纪大道与江南路交叉口北侧 316
    6 首南中路与天童南路交叉口 282
    7 鄞县大道与沧海路交叉口 273
    下载: 导出CSV

    表  4  外部变量值

    Table  4.   External variable values

    变量名 变量值
    节假日 1.普通工作日;2.周末;3.国庆、春节、五一;
    4.元旦、清明、端午、中秋
    事故类型 1.机动车与机动车;2.机动车与非机动车;
    3.机动车与行人;4.其他事故
    事故位置 1.普通路段;2.交叉口;3.停车场;
    4.高架;5.小区/学校/医院/厂矿企业;6.匝道及其他
    事故天气 1.晴天;2.阴天;3.雨天;
    4.雪天;5.冰冻、台风及其他
    事故环境 1.正常环境;2.夜间;
    3.施工路段;4.绿化遮挡及其他
    下载: 导出CSV

    表  5  不同模型对事故黑点区域交通事故预测精度对比

    Table  5.   Comparison of accuracy of traffic accident prediction in accident black spot area by different models

    事故
    黑点
    不同日均事故预测模型ACC/%
    本文
    BiLSTM
    文献[18]
    GRU
    文献[17]
    LSTM
    文献[15]
    BP
    文献[7]
    ARIMA
    文献[12]
    SVR
    黑点1 96.001 92.33 93.326 93.326 93.326 87.631
    黑点2 93.275 93.275 86.626 87.623 86.622 84.326
    黑点3 87.053 80.031 77.062 74.32 70.306 76.331
    黑点4 95.612 91.36 93.362 91.326 87.626 90.003
    黑点5 95.711 95.626 94.629 94.659 93.336 92.394
    黑点6 93.163 86.362 86.254 81.626 84.32 78.326
    黑点7 91.122 85.326 84.622 80.362 75.033 80.336
    平均值 93.134 88.807 87.983 85.220 84.366 84.192
    下载: 导出CSV

    表  6  不同模型对事故黑点区域交通事故预测误差对比

    Table  6.   Comparison of error of traffic accident prediction in accident black spot area by different models

    事故
    黑点
    不同日均事故预测模型RMSE
    本文
    BiLSTM
    文献[18]
    GRU
    文献[17]
    LSTM
    文献[15]
    BP
    文献[7]
    ARIMA
    文献[12]
    SVR
    黑点1 0.024 32 0.088 95 0.043 99 0.059 66 0.035 62 0.049 32
    黑点2 0.080 33 0.151 56 0.159 33 0.178 66 0.243 16 0.216 01
    黑点3 0.129 54 0.180 23 0.190 15 0.176 17 0.226 56 0.243 16
    黑点4 0.173 31 0.213 01 0.200 14 0.221 13 0.216 36 0.247 96
    黑点5 0.037 61 0.063 01 0.045 63 0.049 89 0.075 62 0.059 66
    黑点6 0.041 62 0.091 99 0.112 36 0.117 36 0.096 32 0.145 66
    黑点7 0.159 81 0.230 30 0.241 33 0.229 36 0.343 62 0.269 54
    平均值 0.092 36 0.145 58 0.141 85 0.147 46 0.176 75 0.175 90
    下载: 导出CSV

    表  7  4种神经网络模型对各事故黑点区域交通事故预测精度方差对比

    Table  7.   Comparison of the variance of traffic accident prediction accuracy offour neural network models for each accident black spot area

    事故
    黑点
    不同神经网络模型预测精度方差
    BiLSTM GRU LSTM BP
    黑点1 1.479 66 1.792 62 1.362 11 3.813 12
    黑点2 2.301 62 2.416 11 2.137 45 4.431 61
    黑点3 1.393 26 1.296 11 2.326 11 4.286 11
    黑点4 1.213 62 2.601 60 1.293 61 3.916 14
    黑点5 0.362 32 1.971 06 2.256 16 1.993 11
    黑点6 1.816 15 2.013 06 1.746 11 4.594 41
    黑点7 1.605 48 2.632 11 2.496 21 3.593 67
    平均值 1.453 16 2.103 24 1.945 39 3.804 02
    下载: 导出CSV
  • [1] 赵琳娜. 城市道路交通事故特点及解决对策[J]. 汽车与安全, 2018, 245(5): 68-70. https://www.cnki.com.cn/Article/CJFDTOTAL-QCAQ201805026.htm

    ZHAO L N. Characteristics of urban road traffic accidents and countermeasures[J]. Auto & Safety, 2018, 245(5): 68-70. (in Chinese) https://www.cnki.com.cn/Article/CJFDTOTAL-QCAQ201805026.htm
    [2] GUO Q W. A combined prediction model composed of the GM(1, 1)model and the BP neural network for major road traffic accidents in China[R/OL]. (2022-04) [2023-05-23]. https://www.hindawi.com/journals/mpe/2022/8392759.
    [3] 张志豪, 杨文忠, 袁婷婷, 等. 基于LSTM神经网络模型的交通事故预测[J]. 计算机工程与应用, 2019, 55(14): 249-253, 259. https://www.cnki.com.cn/Article/CJFDTOTAL-JSGG201914037.htm

    ZHANG Z H, YANG W Z, YUAN T T, et al. Traffic accident prediction based on LSTM neural network model[J]. Computer Engineering and Applications, 2019, 55(14): 249-253, 259. (in Chinese) https://www.cnki.com.cn/Article/CJFDTOTAL-JSGG201914037.htm
    [4] ZHOU Z, WANG Y, XIE X, et al. RiskOracle: A minute-level citywide traffic accident forecasting framework[C]. The AAAI Conference on Artificial Intelligence, New York, USA: AAAI, 2020.
    [5] REN H L, SONG Y, WANG J W, et al. A deep learning approach to the citywide traffic accident risk prediction[C]. 21st International Conference on Intelligent Transportation Systems(ITSC), Piscataway, USA: IEEE Press, 2018.
    [6] 杨文忠, 张志豪, 吾守尔·斯拉木, 等. 基于时间序列关系的GBRT交通事故预测模型[J]. 电子科技大学学报, 2020, 49(4): 615-621. https://www.cnki.com.cn/Article/CJFDTOTAL-DKDX202004021.htm

    YANG W Z, ZHANG Z H, WUSHOUER S, et al. GBRT traffic accident prediction model based on time series relationship[J]. Journal of University of Electronic Science and Technology of China, 2020, 49(4): 615-621. (in Chinese) https://www.cnki.com.cn/Article/CJFDTOTAL-DKDX202004021.htm
    [7] 何亚雯. 基于季节性时间序列的道路交通事故数宏观态势分析及预测[D]. 北京: 北京交通大学, 2020.

    HE Y W. Macro situation analysis and prediction of road traffic accidents based on seasonal time series[D]. Beijing: Beijing Jiaotong University, 2020. (in Chinese)
    [8] 马聪, 张生瑞, 马壮林, 等. 高速公路交通事故非线性负二项预测模型[J]. 中国公路学报, 2018, 31(11): 176-185. https://www.cnki.com.cn/Article/CJFDTOTAL-ZGGL201811020.htm

    MA C, ZHANG S R, MA Z L, et al. Nonlinear negative binomial regression model of expressway traffic accident frequency prediction[J]. China Journal of Highway and Transport, 2018, 31(11): 176-185. (in Chinese) https://www.cnki.com.cn/Article/CJFDTOTAL-ZGGL201811020.htm
    [9] 刘星良, 单珏, 刘唐志, 等. 基于交通流稳定性系数的高速公路交通事故实时风险预测[J]. 交通信息与安全, 2022, 40(4): 71-81. doi: 10.3963/j.jssn.1674-4861.2022.04.008

    LIU X L, SHAN J, LIU T Z, et al. Real-time forecast models for traffic accidents on expressways using stability coefficients of traffic flow[J]. Journal of Transport Information and Safety, 2022, 40(4): 71-81. (in Chinese) doi: 10.3963/j.jssn.1674-4861.2022.04.008
    [10] ALFRED L, AHMAD S. Forecasting road traffic accidents: grey system theory GM(1, 1)and grey entropy based approach(GMEPA)[J]. Archives of Current Research International, 2018, 13(2), 1-11.
    [11] LIU S B, WU C W. Road traffic accident forecast based on optimized Grey Verhulst Model[C]. Joint International Information Technology, Mechanical & Electronic Engineering Conference, Xi'an, China: Atlantis Press, 2016.
    [12] WU D L, WANG S M. Comparison of road traffic accident prediction effects based on SVR and BP neural network[C]. 2020 IEEE International Conference on Information Technology, Big Data and Artificial Intelligence(ICIBA), Chongqing, China: IEEE, 2020.
    [13] MARYAM P, ASRIN K, SATAR R, et al. Assessment and prediction of road accident injuries trend using time-series models in Kurdistan[J]. Burns & Trauma, 2018, 6(1): 1-8.
    [14] 宋贺. 基于贝叶斯网络的道路危险货物罐车运输事故预测研究[D]. 北京: 北京交通大学, 2020.

    SONG H. Research on accident prediction of road dangerous goods tanker transportation based on Bayesian network[D]. Beijing: Beijing Jiaotong University, 2020. (in Chinese)
    [15] 李兴兵, 黄力. 基于神经网络的区域交通事故数预测建模研究[J]. 信息系统工程, 2020, 317(5): 139-142, 144. https://www.cnki.com.cn/Article/CJFDTOTAL-XXXT202005064.htm

    LI X B, HUANG L. Research on prediction model of regional traffic accidents base on neural network[J]. China CIO News, 2020, 317(5): 139-142, 144. (in Chinese) https://www.cnki.com.cn/Article/CJFDTOTAL-XXXT202005064.htm
    [16] MA C X, DAI G W, ZHOU J B. Short-term traffic flow prediction for urban road sections based on time series analysis and LSTM_BILSTM method[J]. IEEE Transactions on Intelligent Transportation Systems, 2021, 23(6): 5615-5624.
    [17] 李文书, 邹涛涛, 王洪雁, 等. 基于双尺度长短期记忆网络的交通事故量预测模型[J]. 浙江大学学报(工学版), 2020, 54(8): 1613-1619. https://www.cnki.com.cn/Article/CJFDTOTAL-ZDZC202008021.htm

    LI W S, ZOU T T, WANG H T, et al. Highway traffic accident quantity prediction model based on dual-scale long short-term memory network[J]. Journal of Zhejiang University(Engineering Science), 2020, 54(8): 1613-1619. (in Chinese) https://www.cnki.com.cn/Article/CJFDTOTAL-ZDZC202008021.htm
    [18] 欧洋凯. 基于深度学习的交通预测方法[D]. 长沙: 湖南大学, 2021.

    OU Y K. Traffic prediction method based on deep learning[D]. Changsha: Hunan University, 2021. (in Chinese)
    [19] 卢勇, 姚仕伟, 陈永胜, 等. 高速公路交通事故短时预测及节假日交通安全特征分析[J]. 公路, 2018, 63(11): 224-227.

    LU Y, YAO S W, CHEN Y S. et al. Short-term prediction of highway traffic accidents and analysis of traffic safety characteristics in holidays[J]. Highway, 2018, 63(11): 224-227. (in Chinese)
    [20] 高珍, 高屹, 余荣杰, 等. 连续数据环境下的道路交通事故风险预测模型[J]. 中国公路学报, 2018, 31(4): 280-287. https://www.cnki.com.cn/Article/CJFDTOTAL-ZGGL201804033.htm

    GAO Z, GAO Q, YU R J, et al. Road crash risk prediction model for continuous streaming data environment[J]. China Journal of Highway and Transport, 2018, 31(4): 280-287. (in Chinese) https://www.cnki.com.cn/Article/CJFDTOTAL-ZGGL201804033.htm
    [21] 郭璘, 周继彪, 董升, 等. 基于改进K-means算法的城市道路交通事故分析[J]. 中国公路学报, 2018, 31(4): 270-279. https://www.cnki.com.cn/Article/CJFDTOTAL-ZGGL201804032.htm

    GUO L, ZHOU J B, DONG S, et al. Analysis of urban road traffic accidents based on improved K-means algorithm[J]. China Journal of Highway and Transport, 2018, 31(4): 270-279. (in Chinese) https://www.cnki.com.cn/Article/CJFDTOTAL-ZGGL201804032.htm
    [22] 陶莹, 杨锋, 刘洋, 等. K均值聚类算法的研究与优化[J]. 计算机技术与发展, 2018, 28(6): 90-92. https://www.cnki.com.cn/Article/CJFDTOTAL-WJFZ201806020.htm

    TAO Y, YANG F, LIU Y, et al. Research and optimization of K-means clustering algorithm [J]. Computer Technology and Development, 2018, 28(6): 90-92. (in Chinese) https://www.cnki.com.cn/Article/CJFDTOTAL-WJFZ201806020.htm
    [23] 张嘉瓴. 基于数据挖掘技术的道路交通事故分析[D]. 大连: 大连理工大学, 2020.

    ZHANG J L. Analysis of road traffic accidents based on data mining technology[D]. Dalian: Dalian University of Technology, 2020. (in Chinese)
    [24] 佘鹏果. 基于信号匹配和最优分解层的小波去噪方法研究[D]. 扬州: 扬州大学, 2014.

    SHE P G. Based on signal matching and the optimal decomposition level of wavelet denoising method research[D]. Yangzhou: Yangzhou University, 2014. (in Chinese)
  • 加载中
图(18) / 表(7)
计量
  • 文章访问数:  711
  • HTML全文浏览量:  243
  • PDF下载量:  53
  • 被引次数: 0
出版历程
  • 收稿日期:  2022-05-17
  • 网络出版日期:  2023-06-19

目录

    /

    返回文章
    返回