(Blue) Taxi Destination and Trip Time Prediction from Partial Trajectories

Hoang Thanh Lam, Ernesto Diaz-Aviles, Alessandra Pascale, Yiannis Gkoufas, Bei Chen

Abstract

Real-time estimation of destination and travel time for taxis is of great importance for existing electronic dispatch systems. We present an approach based on trip matching and ensemble learning, in which we leverage the patterns observed in a dataset of roughly 1.7 million taxi journeys to predict the corresponding final destination and travel time for ongoing taxi trips, as a solution for the ECML/PKDD Discovery Challenge 2015 competition. The results of our empirical evaluation show that our approach is effective and very robust, which led our team -- BlueTaxi -- to the 3rd and 7th position of the final rankings for the trip time and destination prediction tasks, respectively. Given the fact that the final rankings were computed using a very small test set (with only 320 trips) we believe that our approach is one of the most robust solutions for the challenge based on the consistency of our good results across the test sets.

1. Introduction

In modern urban environments, efficient taxi dispatching is a complex logistical challenge. Ideally, a dispatcher should know a taxi's destination to pre-assign the next passenger nearby, minimizing idle time. However, taxi drivers rarely report their final destination to the system. This research addresses the "Partial Trajectory" problem: given the initial GPS coordinates of a taxi ride, can we accurately predict the final stop and the remaining travel time?

This study utilizes the dataset from the ECML/PKDD Discovery Challenge 2015, consisting of approximately 1.7 million taxi journeys in Porto, Portugal. Collected over one year from 442 taxis, the data provides GPS updates every 15 seconds, presenting a significant opportunity to model urban mobility patterns.

2. Methodology

The BlueTaxi approach bifurcates the problem into two distinct tasks: destination prediction and trip time estimation.

2.1 Destination Prediction: Trajectory Matching

The core strategy for destination prediction relies on Trip Matching. The intuition is that if a taxi follows a path similar to historical trips, it is likely heading toward a similar destination.

Figure 1: Visualization of partial taxi trajectories in Porto, illustrating the path matching problem.

To implement this, the team used Kernel Regression (KR) to find "nearest neighbors" in the historical dataset. To handle noisy GPS data, the Ramer-Douglas-Peucker (RDP) algorithm was applied to smooth trajectories before matching. Furthermore, the model incorporated contextual features like "Call ID," recognizing that individual callers often have predictable destination patterns.

2.2 Trip Time Prediction: Stacked Generalization

For travel time estimation, the researchers employed a Stacked Generalization approach. They trained several base models, including Gradient Boosted Regression Trees (GBRT), Random Forests (RF), and Extremely Randomized Trees (ERT). The outputs of these models were then fed into a final "meta-regressor" (using Lasso or simple averaging). This ensemble method ensures the system remains robust even if a specific model fails on an outlier trip. Additionally, the team predicted the log-transformed remaining time to better manage the variance between short hops and long hauls.

3. Key Insights

  • The "Last Meters" Rule: The researchers discovered that the final 500 to 700 meters of a partial trajectory are the most critical for predicting the destination. Early trip segments are often too generic to provide high predictive value.
  • Call ID Predictability: Utilizing the "Call ID" to create contextual models significantly outperformed generic models. Passengers are often creatures of habit, and knowing the caller allows the system to narrow down potential destinations using historical heatmaps.
Figure 2: Heatmap showing clusters of frequent taxi destinations in Porto, highlighting the predictability of certain trips.

4. Results and Discussion

The BlueTaxi approach proved highly effective in the competition rankings:

  • Trip Time Prediction: Ranked 3rd place globally (RMSLE of 0.53097).
  • Destination Prediction: Ranked 7th place globally (Mean Haversine Distance error of 2.14 km).

The team prioritized model robustness over public leaderboard precision. Because the final test set was very small (320 trips), they chose models like Random Forests that were less likely to overfit. Interestingly, one of their ensemble strategies (ME2) would have secured 1st place in the competition, but was not selected as the final submission because it performed slightly worse on the public leaderboard during the contest phase.

5. Conclusion

While the BlueTaxi system is robust, challenges remain regarding data quality, such as erroneous "missing value" flags and taxi meters left running after trips end. Future work will focus on improving computational efficiency for real-time deployment and generalizing the approach to automatically adapt to different urban contexts and weather conditions without manual feature engineering.

Summary updated

BibTeX
@inproceedings{lam2015blue,
  author = {Hoang Thanh Lam and Ernesto Diaz-Aviles and Alessandra Pascale and Yiannis Gkoufas and Bei Chen},
  title = {{(Blue) Taxi Destination and Trip Time Prediction from Partial Trajectories}},
  booktitle = {DC@PKDD/ECML},
  year = {2015},
  url = {https://openreview.net/forum?id=LK4FIcNCN8},
}
Figure