The invention relates to a traffic flow prediction method based on a multi-head attention mechanism. The method comprises the steps that a road network geographic map of a target area where a target road is located and historical traffic flow data of the road network geographic map are acquired; constructing a geographic neighborhood sub-graph and a semantic similarity sub-graph; respectively calculating weights between road nodes and adjacent nodes in the geographic neighborhood sub-graph and the semantic similarity sub-graph by utilizing a multi-head attention mechanism, and updating an adjacent matrix of the geographic neighborhood sub-graph and the semantic similarity sub-graph; fusing the adjacent matrixes of the updated geographic neighborhood sub-graph and the semantic similarity sub-graph by using a parameter fusion method to obtain a fusion matrix, and extracting a spatial-temporal feature sequence of a target road node by using GCN according to the fusion matrix; and inputting the spatial-temporal feature sequence of the target road node and the traffic flow data of the target road node into a bidirectional GRU model, and obtaining a traffic flow prediction result of the target road node through a full connection layer according to forward output and reverse output of the bidirectional GRU model.
本发明涉及一种基于多头注意力机制的交通流预测方法,包括获取目标道路所在目标区域的路网地理图及其历史交通流数据;构建地理邻域子图和语义相似性子图;利用多头注意力机制分别计算地理邻域子图和语义相似性子图中道路节点与其相邻节点之间的权重,更新地理邻域子图和语义相似性子图的邻接矩阵;利用参数融合法将更新后的地理邻域子图和语义相似性子图的邻接矩阵进行融合得到融合矩阵,根据融合矩阵利用GCN提取目标道路节点的时空特征序列;将目标道路节点的时空特征序列和目标道路节点的交通流数据输入双向GRU模型,根据双向GRU模型的正向输出和反向输出通过全连接层得到目标道路节点的交通流预测结果。
Traffic flow prediction method based on multi-head attention mechanism
一种基于多头注意力机制的交通流预测方法
2023-11-10
Patent
Electronic Resource
Chinese
IPC: | G08G Anlagen zur Steuerung, Regelung oder Überwachung des Verkehrs , TRAFFIC CONTROL SYSTEMS / G06N COMPUTER SYSTEMS BASED ON SPECIFIC COMPUTATIONAL MODELS , Rechnersysteme, basierend auf spezifischen Rechenmodellen / G06Q Datenverarbeitungssysteme oder -verfahren, besonders angepasst an verwaltungstechnische, geschäftliche, finanzielle oder betriebswirtschaftliche Zwecke, sowie an geschäftsbezogene Überwachungs- oder Voraussagezwecke , DATA PROCESSING SYSTEMS OR METHODS, SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL, SUPERVISORY OR FORECASTING PURPOSES |
European Patent Office | 2025
|Multi-node traffic flow prediction method based on simplified attention mechanism
European Patent Office | 2025
|Traffic flow prediction method based on attention mechanism
European Patent Office | 2022
|Urban traffic flow online prediction based on multi-component attention mechanism
IET | 2020
|Urban traffic flow online prediction based on multi‐component attention mechanism
Wiley | 2020
|