Name: Towards AI Legal Name: Towards AI, Inc. Description: Towards AI is the world's leading artificial intelligence (AI) and technology publication. Read by thought-leaders and decision-makers around the world. Phone Number: +1-650-246-9381 Email: [email protected]
228 Park Avenue South New York, NY 10003 United States
Website: Publisher: https://towardsai.net/#publisher Diversity Policy: https://towardsai.net/about Ethics Policy: https://towardsai.net/about Masthead: https://towardsai.net/about
Name: Towards AI Legal Name: Towards AI, Inc. Description: Towards AI is the world's leading artificial intelligence (AI) and technology publication. Founders: Roberto Iriondo, , Job Title: Co-founder and Advisor Works for: Towards AI, Inc. Follow Roberto: X, LinkedIn, GitHub, Google Scholar, Towards AI Profile, Medium, ML@CMU, FreeCodeCamp, Crunchbase, Bloomberg, Roberto Iriondo, Generative AI Lab, Generative AI Lab Denis Piffaretti, Job Title: Co-founder Works for: Towards AI, Inc. Louie Peters, Job Title: Co-founder Works for: Towards AI, Inc. Louis-François Bouchard, Job Title: Co-founder Works for: Towards AI, Inc. Cover:
Towards AI Cover
Logo:
Towards AI Logo
Areas Served: Worldwide Alternate Name: Towards AI, Inc. Alternate Name: Towards AI Co. Alternate Name: towards ai Alternate Name: towardsai Alternate Name: towards.ai Alternate Name: tai Alternate Name: toward ai Alternate Name: toward.ai Alternate Name: Towards AI, Inc. Alternate Name: towardsai.net Alternate Name: pub.towardsai.net
5 stars – based on 497 reviews

Frequently Used, Contextual References

TODO: Remember to copy unique IDs whenever it needs used. i.e., URL: 304b2e42315e

Resources

Take our 85+ lesson From Beginner to Advanced LLM Developer Certification: From choosing a project to deploying a working product this is the most comprehensive and practical LLM course out there!

Publication

Traffic Forecasting: The Power of Graph Convolutional Networks on Time Series
Latest

Traffic Forecasting: The Power of Graph Convolutional Networks on Time Series

Last Updated on February 13, 2023 by Editorial Team

Author(s): Barak Or

Originally published on Towards AI.

The Graph Convolutional Network (GCN) has revolutionized the field of deep learning by showcasing its versatility in solving real-world problems, including traffic prediction, which is a critical issue in transportation.

Introduction

The Graph Convolutional Network (GCN) is a revolutionary development in the field of deep learning, demonstrating its versatility and potential for application in addressing real-world problems. One such challenge is traffic prediction, which is a critical issue in transportation. The ability to adapt GCN algorithms for traffic prediction purposes holds immense promise and has the potential to significantly impact the transportation industry.

It is important to note that this post assumes a prior understanding of GCN. For those who require an introduction to GCN, I strongly recommend exploring Michael Bronstein’s post, β€œDo we need deep GNN,” as well as Tobias Skovgaard Jepsen's hands-on introductory post.

The power of Graph Neural Networks (GNN) [1], particularly GCN, lies in their ability to model complex relationships between entities, as demonstrated through examples such as chemical bonds between atoms or traffic speeds between road segments. With its capability for feature learning through graph convolutional operations, GCN has seen wide research in vision and text data, yet there is still much potential for exploring its application in the time-series domain, unlocking new frontiers for innovation.

Image byΒ author

Exploring Time-Series Tasks with TemporalΒ GCN

The advent of GCN has opened up new possibilities for analyzing and understanding graph-structured data, including time-series data. Time-series data presents unique challenges compared to other forms of data, such as images. It is often less intuitive, lacks clear visual representations, and requires a deep understanding of causality to be analyzed effectively.

To address these challenges, a new field of research known as Temporal GCN (TGCN) has emerged, which combines the strengths of GCN with those of Recurrent Neural Networks (RNN), Long-Short Term Memory (LSTM), or Gated Recurrent Units (GRU). This allows TGCN to capture both the spatial and temporal aspects of time-series data, making it a powerful tool for analyzing complex and dynamicΒ systems.

Next, we will explore the potential of TGCN for traffic prediction [2], which is a critical issue in transportation. By analyzing traffic patterns and dependencies between different road segments over time, TGCN can provide insights and make accurate predictions about future traffic conditions. Through this example, we aim to demonstrate the versatility and potential of TGCN for solving real-world problems and improving our understanding of time-series data.

Temporal GCN For Traffic Prediction

Traffic prediction is a critical issue in transportation, and finding an accurate solution is crucial for optimizing traffic flow and reducing congestion. Traditional methods of predicting traffic speed only consider the past values of the same time series, but with the advent of GCN and GRU, a more comprehensive approach is possible.

In a recent study [2], a new approach to traffic prediction was proposed that leverages the strengths of GCN and GRU. The researchers modeled the traffic network as a graph, with each road segment being a node and the connections between segments being the edges. The traffic speed was then represented as a signal on this graph, allowing the model to capture both the spatial and temporal features of theΒ data.

The architecture included a graph convolution layer and a GRU layer, which enabled the model to effectively capture the relationships between different road segments and predict future traffic speed. By taking into account the dependencies between road segments, this solution provides a more accurate and comprehensive traffic prediction than traditional methods.

Image byΒ author

Exploring the Road SegmentsΒ Dataset

In order to understand if there is any dependency between different road segments, we need to analyze the correlations between them. To do this, we selected 26 roads out of the 228 available in the dataset and created a correlation map.

By visualizing the correlations, we can see if there is any relationship between the traffic speed of different road segments. If there is a strong relationship, this provides a clear justification for the use of a GCN to model the dependencies.

It’s important to note that capturing these relationships is crucial in accurately predicting traffic speed. By using a GCN, we can consider not only the individual traffic speed of each road segment but also the interdependencies between segments. This holistic approach allows for a more accurate and robust prediction of trafficΒ speed.

Image byΒ author

To understand if there are any dependencies between different road segments in the dataset, we calculated the correlations. The results showed that segments 4–5–6–7 and 19–20–21 have a high correlation, highlighting the importance of incorporating spatial features. In their research, Ling Zhao and their team proposed a TGCN architecture that utilizes both spatial and temporal features, with a graph convolution layer for the former and a GRU layer for the latter. We played with their code [3] and made it accessible through a Google Colab notebook, providing an opportunity for you to easily experiment with it [4]. The results were promising, and we encourage you to further test and improve the model by adjusting the parameters and increasing the number ofΒ epochs.

Keras.io Time-series traffic forecasting Tutorial

Summary

The graph convolutional network (GCN) is a highly innovative and impactful development in deep learning. It has numerous applications in the time-series domain, where it is adapted to include temporal features. To showcase the capabilities of TGCN, the example of traffic speed prediction was used and the correlation map was shown to highlight the need for the inclusion of spatial features.

follow me on Medium for moreΒ posts

About theΒ Author

Barak Or is an Entrepreneur and AI & navigation expert; Ex-Qualcomm. Barak holds M.Sc. and B.Sc. in Engineering and B.A. in Economics from the Technion. Winner of Gemunder prize. Barak finished his Ph.D. in the fields of AI and Sensor Fusion. Author of several papers and patents. He is the founder and CEO of ALMA Tech. LTD, an AI & advanced navigation company.

Further reading andΒ comments

[1] GCNs were first introduced in β€œSpectral Networks and Deep Locally Connected Networks on Graphs” (Bruna et al,Β 2014).

[2] A paper named β€œT-GCN: A Temporal Graph Convolutional Network for Traffic Prediction” by Ling Zhao et al was published in IEEE,Β 2020.

[3] The accompanied code can be found on the tutorial page of Keras. on the website. Arash Khodadadi is the author of the Keras tutorial for this paper. Data inΒ [6].

[4] Colab implementation: Timeseries_Traffic_Forecasting. The dataset is fromΒ [3].

[5] Do we need deep graph neural networksβ€Šβ€”β€Šby Michael Bronstein

[6] The data can be found at the Keras website at the following link: https://keras.io/examples/timeseries/timeseries_traffic_forecasting/


Traffic Forecasting: The Power of Graph Convolutional Networks on Time Series was originally published in Towards AI on Medium, where people are continuing the conversation by highlighting and responding to this story.

Join thousands of data leaders on the AI newsletter. Join over 80,000 subscribers and keep up to date with the latest developments in AI. From research to projects and ideas. If you are building an AI startup, an AI-related product, or a service, we invite you to consider becoming aΒ sponsor.

Published via Towards AI

Feedback ↓