lane-level-traffic-prediction-eval
Unifying Lane-Level Traffic Prediction from a Graph Structural Perspective: Benchmark and Baseline — Shuhao Li et al. (arXiv:2403.14941, 2024)
What this evaluates
Evaluates models' ability to predict lane-level traffic speed and flow by modeling spatio-temporal dependencies on graph-structured lane networks. It tests performance across both regular and irregular lane configurations, emphasizing both predictive accuracy and training efficiency.
Datasets
Metrics
MAE (primary) — range: [0, ∞)
- MAE = (1/z) * Σ_{t=1}^z (1/N) * Σ_{j=1}^J (1/I) * Σ_{i=1}^I |y_t^{l_{i,j}} - ŷ_t^{l_{i,j}}|, where z is prediction horizon, N is number of time steps, J is lanes, I is segments.
RMSE — range: [0, ∞)
- RMSE = sqrt((1/z) * Σ_{t=1}^z (1/N) * Σ_{j=1}^J (1/I) * Σ_{i=1}^I (y_t^{l_{i,j}} - ŷ_t^{l_{i,j}})^2).
MAPE — range: percent
- MAPE = (1/z) * Σ_{t=1}^z (1/N) * Σ_{j=1}^J (1/I) * Σ_{i=1}^I |y_t^{l_{i,j}} - ŷ_t^{l_{i,j}}| / y_t^{l_{i,j}}.
Cost — range: seconds
- Training expenditure metric calculated as the time required for each iteration of model training multiplied by 100 (or 10^-2 per table), unit in seconds.
Input / output format
Input: Time-series speed and flow measurements from traffic sensors across multiple lanes, organized according to the physical lane topology (graph structure).
Output: Predicted speed and flow values for each lane segment at specified future time horizons (e.g., 3, 6, 12 steps).
Scoring recipe
def compute_metrics(y_true, y_pred, z, N, J, I):
# y_true, y_pred shape: (z, N, J, I)
mae = np.mean(np.abs(y_true - y_pred))
rmse = np.sqrt(np.mean((y_true - y_pred) ** 2))
mape = np.mean(np.abs((y_true - y_pred) / y_true)) * 100
return mae, rmse, mape
Common pitfalls
- Models must handle irregular lane counts (e.g., entrance lanes adding a 6th lane) without breaking graph topology assumptions.
- Training cost is evaluated as a first-class metric (time per iteration * 10^-2), not just accuracy; ignoring efficiency misrepresents practical utility.
- Missing data is imputed using adjacent time slot means, which may smooth out sudden traffic spikes and affect MAPE/RMSE.
Evidence (verbatim from paper)
In the field of traffic prediction, particularly at the lane level, a model’s accuracy is typically assessed using three key metrics: Root Mean Square Error (RMSE), Mean Absolute Error (MAE), and Mean Absolute Percentage Error (MAPE). However, beyond accuracy, the practicality of a model also hinges on the duration of its training. This is especially crucial in lane-level traffic prediction scenarios where rapid response and real-time updates are essential. Therefore, focusing solely on predictive accuracy while overlooking training time could limit the model’s performance in practical applications. Acknowledging this, we have included training expenditure as an evaluation metric, aiming to ensure that models consider both training time and predictive accuracy. The training Cost metric is calculated as the time required for each iteration of model training multiplied by 100, with the unit being seconds.
Citation
@misc{li2024unifying,
title={Unifying Lane-Level Traffic Prediction from a Graph Structural Perspective: Benchmark and Baseline},
author={Shuhao Li et al.},
year={2024},
note={arXiv:2403.14941}
}
1---2name: lane-level-traffic-prediction-eval3description: Evaluates models' ability to predict lane-level traffic speed and flow by modeling spatio-temporal dependencies on graph-structured lane networks. It tests performance across both regular and irregular lane configurations, emphasizing both predictive accuracy and training efficiency. Use when the user wants to benchmark on PeMS, PeMSF, HuaNan, or asks about evaluating this task. Reports MAE.4---56# lane-level-traffic-prediction-eval78> Unifying Lane-Level Traffic Prediction from a Graph Structural Perspective: Benchmark and Baseline — Shuhao Li et al. (arXiv:2403.14941, 2024)910## What this evaluates1112Evaluates models' ability to predict lane-level traffic speed and flow by modeling spatio-temporal dependencies on graph-structured lane networks. It tests performance across both regular and irregular lane configurations, emphasizing both predictive accuracy and training efficiency.1314## Datasets1516- **PeMS** — total ?; splits: train (-1), val (-1), test (-1); repo https://github.com/ShuhaoLii/TITS24LaneLevel-Traffic-Benchmark17- **PeMSF** — total ?; splits: train (-1), val (-1), test (-1); repo https://github.com/ShuhaoLii/TITS24LaneLevel-Traffic-Benchmark18- **HuaNan** — total ?; splits: train (-1), val (-1), test (-1); repo https://github.com/ShuhaoLii/TITS24LaneLevel-Traffic-Benchmark1920## Metrics2122- `MAE` **(primary)** — range: [0, ∞)23 - MAE = (1/z) * Σ_{t=1}^z (1/N) * Σ_{j=1}^J (1/I) * Σ_{i=1}^I |y_t^{l_{i,j}} - ŷ_t^{l_{i,j}}|, where z is prediction horizon, N is number of time steps, J is lanes, I is segments.24- `RMSE` — range: [0, ∞)25 - RMSE = sqrt((1/z) * Σ_{t=1}^z (1/N) * Σ_{j=1}^J (1/I) * Σ_{i=1}^I (y_t^{l_{i,j}} - ŷ_t^{l_{i,j}})^2).26- `MAPE` — range: percent27 - MAPE = (1/z) * Σ_{t=1}^z (1/N) * Σ_{j=1}^J (1/I) * Σ_{i=1}^I |y_t^{l_{i,j}} - ŷ_t^{l_{i,j}}| / y_t^{l_{i,j}}.28- `Cost` — range: seconds29 - Training expenditure metric calculated as the time required for each iteration of model training multiplied by 100 (or 10^-2 per table), unit in seconds.3031## Input / output format3233**Input**: Time-series speed and flow measurements from traffic sensors across multiple lanes, organized according to the physical lane topology (graph structure).3435**Output**: Predicted speed and flow values for each lane segment at specified future time horizons (e.g., 3, 6, 12 steps).3637## Scoring recipe3839```python40def compute_metrics(y_true, y_pred, z, N, J, I):41 # y_true, y_pred shape: (z, N, J, I)42 mae = np.mean(np.abs(y_true - y_pred))43 rmse = np.sqrt(np.mean((y_true - y_pred) ** 2))44 mape = np.mean(np.abs((y_true - y_pred) / y_true)) * 10045 return mae, rmse, mape46```4748## Common pitfalls4950- Models must handle irregular lane counts (e.g., entrance lanes adding a 6th lane) without breaking graph topology assumptions.51- Training cost is evaluated as a first-class metric (time per iteration * 10^-2), not just accuracy; ignoring efficiency misrepresents practical utility.52- Missing data is imputed using adjacent time slot means, which may smooth out sudden traffic spikes and affect MAPE/RMSE.5354## Evidence (verbatim from paper)5556> In the field of traffic prediction, particularly at the lane level, a model’s accuracy is typically assessed using three key metrics: Root Mean Square Error (RMSE), Mean Absolute Error (MAE), and Mean Absolute Percentage Error (MAPE). However, beyond accuracy, the practicality of a model also hinges on the duration of its training. This is especially crucial in lane-level traffic prediction scenarios where rapid response and real-time updates are essential. Therefore, focusing solely on predictive accuracy while overlooking training time could limit the model’s performance in practical applications. Acknowledging this, we have included training expenditure as an evaluation metric, aiming to ensure that models consider both training time and predictive accuracy. The training Cost metric is calculated as the time required for each iteration of model training multiplied by 100, with the unit being seconds.5758## Citation5960```bibtex61@misc{li2024unifying,62 title={Unifying Lane-Level Traffic Prediction from a Graph Structural Perspective: Benchmark and Baseline},63 author={Shuhao Li et al.},64 year={2024},65 note={arXiv:2403.14941}66}67```6869- arXiv: 2403.14941