dmariaa70/GO-MO
GO-MO: A large-scale graph-augmented traffic dataset for data-driven spatio-temporal traffic analysis This is the official dataset repository for the GO-MO traffic dataset. The GO-MO dataset is a traffic dataset extracted from the publicly available Open Data Portal of the City Council of Madrid (Spain). GO-MO comprises more than 1.5 billion records of three traffic-related metrics together with spatio-temporal data and metadata, spanning a ten-year period (2015-2024).β¦ See the full description on the dataset page: https://huggingface.co/datasets/dmariaa70/GO-MO.
GO-MO: A large-scale graph-augmented traffic dataset for data-driven spatio-temporal traffic analysis
This is the official dataset repository for the GO-MO traffic dataset.
The GO-MO dataset is a traffic dataset extracted from the publicly available Open Data Portal of the City Council of Madrid (Spain).
GO-MO comprises more than 1.5 billion records of three traffic-related metrics together with spatio-temporal data and metadata, spanning a ten-year period (2015-2024). Additionally, the GO-MO dataset introduces two graph representations extracted from traffic data and metadata: one for routes between nodes and another for the road network.
π Statistics
Traffic data:
- Total number of timestamps: 350,688 between 01/01/2015 00:00:00 and 31/12/2024 23:45:00 at 15 minutes interval.
- Total number of records: 1,523,167,456
- Number of measure points (traffic sensors): 5,157
- Traffic magnitudes: 3 (traffic intensity, average speed, sensor occupancy)
- Traffic sensors metadata: 6 variables (sensor type, district, road name, number of lanes, maximum speed, maximum capacity) plus UTM and GCS WGS84 location.
Graphs:
- Route based graph:
- Graph type: Directed
- Number of nodes: 5,157
- Number of edges: 135,428
- Average degree: 52.522
- Road network based graph:
- Graph type: Multidirected graph
- Number of nodes: 35,304
- Number of edges: 69,362
- Average degree: 3,929
π File structure and data fields
The GO-MO release contains yearly traffic data files, one sensor metadata file, and two graph files:
GO-MO/
βββ traffic_data_2015.csv
βββ traffic_data_2016.csv
βββ traffic_data_2017.csv
βββ traffic_data_2018.csv
βββ traffic_data_2019.csv
βββ traffic_data_2020.csv
βββ traffic_data_2021.csv
βββ traffic_data_2022.csv
βββ traffic_data_2023.csv
βββ traffic_data_2024.csv
βββ traffic_sensors.csv
βββ routes-graph.pkl
βββ road-network-graph.pklYearly traffic files: traffic_data_YYYY.csv
Each yearly file contains the traffic measurements for one calendar year, where YYYY ranges from 2015 to 2024. Each row corresponds to one traffic sensor at one 15-minute timestamp.
Interpolation flag: is_interpolated
The is_interpolated field is a three-character string flag. The first, second, and third positions correspond to traffic_intensity, sensor_occupancy, and avg_speed, respectively.
A value of 1 indicates that the corresponding value was interpolated during the GO-MO curation process. A value of 0 indicates that the corresponding value is original and unmodified.
Sensor metadata file: traffic_sensors.csv
The file traffic_sensors.csv contains one row per traffic sensor and provides the metadata needed to interpret and spatially locate the measurements.
Graph files
GO-MO provides two graph representations of the traffic sensor and road network structure. Both graph files are released as Python NetworkX pickle files.
Security note on pickle files: the graph files are distributed as Python pickle files for compatibility with NetworkX workflows. Pickle files can execute arbitrary code when loaded. Only loadroutes-graph.pklandroad-network-graph.pklif they were obtained from this official GO-MO repository or another trusted source.
Relationship between CSV files and graph nodes
The released files are linked through the sensor identifier:
- In
traffic_data_YYYY.csv, the fieldsensor_ididentifies the sensor that produced each traffic record. - In
traffic_sensors.csv, the fieldidcontains the corresponding sensor metadata. - In
routes-graph.pkl, each node represents a traffic sensor and includes the corresponding sensor identifier. - In
road-network-graph.pkl, the road network is represented explicitly; the road-network elements associated with traffic sensors include the correspondingsensor_idattribute.
Therefore, users can join the yearly traffic files with traffic_sensors.csv using:
traffic_data_YYYY.csv.sensor_id = traffic_sensors.csv.idThe same sensor identifiers can be used to relate the tabular data to the graph representations.
Main graph attributes
The exact set of graph attributes may vary depending on the OpenStreetMap information available for each road segment. The main attributes are:
π§ Tools and Code
- π¦ Dataset: Hugging Face Dataset Page
- π οΈπ§ͺ Source code and experiments: GO-MO source code
π Minimal Python loading example
After downloading one or more CSV files, the sensor metadata CSV or the graph pickle files, you can load them with the following code. The example assumes that the files are located in the current working directory.
Security note on pickle files: the graph files are distributed as Python pickle files for compatibility with NetworkX workflows. Pickle files can execute arbitrary code when loaded. Only loadroutes-graph.pklandroad-network-graph.pklif they were obtained from this official GO-MO repository or another trusted source.
import pickle
import pandas as pd
# Load one yearly traffic file
traffic_2024 = pd.read_csv(
"traffic_data_2024.csv",
parse_dates=["entry_date"],
dtype={
"sensor_id": "string",
"read_error": "string",
"is_interpolated": "string",
},
)
# Load sensor metadata
sensors = pd.read_csv(
"traffic_sensors.csv",
dtype={
"id": "string",
"element_type": "string",
"internal_code": "string",
"name": "string",
"osm_name": "string",
},
)
# Join traffic records with sensor metadata
traffic_2024_with_metadata = traffic_2024.merge(
sensors,
left_on="sensor_id",
right_on="id",
how="left",
)
# Load the Routes Graph (RG)
with open("routes-graph.pkl", "rb") as f:
routes_graph = pickle.load(f)
# Load the Road Network Graph (RNG)
with open("road-network-graph.pkl", "rb") as f:
road_network_graph = pickle.load(f)
print(traffic_2024.shape)
print(sensors.shape)
print(routes_graph.number_of_nodes(), routes_graph.number_of_edges())
print(road_network_graph.number_of_nodes(), road_network_graph.number_of_edges())πΎ Data sources
The original data published in this dataset is available on the Open Data Portal of the City Council of Madrid (Spain).
π License
This Dataset is licensed under the CC-BY 4.0.
You are free to:
- β Share β copy and redistribute the material in any medium or format for any purpose, even commercially.
- β Adapt β remix, transform, and build upon the material for any purpose, even commercially.
The full license text is available here.
π Citation
GO-MO has its own dataset DOI. If you use the released dataset files, metadata, or graph files, please cite the dataset record:
@dataset{maria_arribas2025gomo,
author = {MarΓa-Arribas, David and Cuesta-Infante, Alfredo and Pantrigo, Juan J.},
title = {{GO-MO: A large-scale graph-augmented traffic dataset for data-driven spatio-temporal traffic analysis}},
year = {2025},
publisher = {Hugging Face},
version = {1.0},
doi = {10.57967/hf/7201},
url = {https://doi.org/10.57967/hf/7201}
}If you also refer to the scientific description, methodology, data curation process, graph construction, or validation analyses, please cite the associated article as well. The article citation will be updated here once the final published version is available.
@misc{maria_arribas2026large_scale,
author = {MarΓa-Arribas, David and Pantrigo, Juan J. and Cuesta-Infante, Alfredo},
title = {{A large-scale graph-augmented traffic dataset for data-driven spatio-temporal traffic analysis}},
year = {2026},
note = {Preprint},
publisher = {Research Square},
doi = {10.21203/rs.3.rs-8670080/v1},
url = {https://doi.org/10.21203/rs.3.rs-8670080/v1}
}