AI for Transportation & Traffic Engineering
Traffic Demand Forecasting, Pavement Deterioration Modelling, and Accident Black Spot Analysis
Traffic Demand Forecasting with Indian Vehicle Mix
Traffic demand forecasting for Indian highways has a fundamental complication that western models ignore: the vehicle mix. A single carriageway NH in Rajasthan carries two-wheelers (25-35% by count), auto-rickshaws, tractors with trailers, bullock carts (yes, still), LCVs, multi-axle trucks, and the occasional overloaded 16-wheeler that counts as two standard axle loads. PCU (Passenger Car Unit) conversion per IRC:64-2017 is the standard approach, but the conversion factors are static — a tractor at 30 km/h on a 2-lane road has a very different capacity impact than the same tractor on a 4-lane divided carriageway.
Open data/traffic-count-data.csv in the code panel. Each row is a classified traffic count: station_id, date, hour, direction, vehicle_class (two_wheeler/auto/car/lcv/bus/2_axle_truck/3_axle_truck/mav/tractor/other), count, speed_kmph, headway_sec, nh_number, carriageway_type, terrain.
Dynamic PCU Estimation
IRC:64 PCU factors (car = 1.0, bus = 3.0, truck = 3.0, two-wheeler = 0.5, tractor = 4.5) are averages that hide significant variance. A regression model trained on speed-flow-density data from 100+ NHAI traffic count stations estimates effective PCU as a function of volume/capacity ratio:
| Vehicle Class | IRC:64 PCU | AI-Estimated PCU (V/C < 0.5) | AI-Estimated PCU (V/C > 0.8) |
|---|---|---|---|
| Two-wheeler | 0.5 | 0.3 | 0.75 |
| Auto-rickshaw | 1.0 | 0.8 | 1.4 |
| Tractor | 4.5 | 3.0 | 7.0 |
| MAV truck | 3.0 | 2.5 | 4.5 |
| Bus | 3.0 | 2.8 | 3.5 |
The key insight: slow vehicles (tractors, autos) have disproportionately higher capacity impact at high V/C ratios because they create platoons and reduce passing opportunities. Using dynamic PCU instead of static factors changes the capacity analysis conclusion (i.e., the year when widening is needed) by 2-4 years on single-carriageway NHs.
Trip Generation and Growth Forecasting
For new highway projects (DPR preparation under Bharatmala), traffic demand forecasting uses:
Short-term (1-5 years): Trend extrapolation
- Historical AADT growth rates from NHAI toll data (4-8% for NHs, 2-4% for SHs)
- Adjusted for GDP elasticity (traffic growth / GDP growth ≈ 1.0-1.3 for freight, 1.5-2.0 for passenger)
Long-term (5-20 years): Gravity model with AI calibration
- Trip generation: f(population, GDP, employment, vehicle ownership) per taluk
- Trip distribution: gravity model with impedance function calibrated on observed OD data
- ML calibration: Random Forest learns the residual between gravity model prediction and actual toll data
- Key features: competing routes (presence of parallel toll-free SH), rail connectivity, fuel price indexOn 30 NHAI projects where DPR traffic forecasts could be compared with actual traffic (5+ years post-opening), the ML-calibrated gravity model had MAPE of 18% — versus 32% for the standard gravity model and 25% for trend extrapolation. The improvement is driven by learning the "diversion effect" — traffic that shifts from parallel routes to the new highway, which the standard gravity model consistently underpredicts.
Pavement Deterioration Modelling: PCI, IRI, and Rutting
Pavement management is the largest single maintenance expenditure for NHAI and state PWDs. The decision: when to overlay, when to reconstruct, and where to allocate limited maintenance budgets. These decisions require deterioration prediction — forecasting future pavement condition from current condition, traffic loading, climate, and pavement structure.
Open data/pavement-condition-data.csv — columns: section_id, survey_date, chainage_km, pavement_type (flexible/rigid/composite), thickness_mm, subgrade_cbr, drainage_condition, climate_zone, cumulative_msa (million standard axles), pci (0-100), iri_m_km (International Roughness Index), rut_depth_mm, cracking_area_pct, pothole_count_per_km, last_overlay_date, last_overlay_thickness_mm.
IRI Prediction Model
IRI (International Roughness Index) is the primary ride quality metric. IRC:SP:16-2019 uses the HDM-4 deterioration model — a mechanistic-empirical model with calibrated coefficients. The HDM-4 model works well for average conditions but struggles with:
An XGBoost model trained on 5 years of network-level pavement survey data (NHAI, 50,000+ km) predicts IRI at next survey (1-year horizon):
| Feature | SHAP Importance |
|---|---|
| current_iri | 0.28 |
| cumulative_msa | 0.18 |
| drainage_condition | 0.14 |
| cracking_area_pct | 0.12 |
| pavement_age_since_last_overlay | 0.10 |
| **climate_zone** (hot_wet/hot_dry/cold) | 0.08 |
| subgrade_cbr | 0.06 |
| overlay_thickness_mm | 0.04 |
MAE: 0.4 m/km (median IRI: 3.5 m/km). The model outperforms HDM-4 by 35% on Indian data, primarily because it captures the drainage and overloading effects that HDM-4 underestimates.
Rutting and Cracking Prediction
Rutting (primarily in flexible pavements) and cracking (fatigue alligator cracking and thermal transverse cracking) are predicted separately:
Accident Black Spot Analysis and Countermeasure Prioritization
India records 4.6 lakh road accidents and 1.7 lakh fatalities annually (MoRTH 2023 report). Black spot identification per IRC:SP:88-2019 uses a simple frequency threshold — locations with 5+ accidents in 3 years. This identifies locations but does not quantify risk, predict future accidents, or prioritize countermeasures cost-effectively.
Open data/accident-data.json — it contains: accident_id, location_km, nh_number, date, time, severity (fatal/grievous/minor/damage_only), vehicle_types_involved, cause_coded (MoRTH classification), road_geometry (straight/curve/intersection/bridge), lighting, weather, surface_condition, speed_limit_kmph, median_type, shoulder_width_m, pedestrian_involved.
Predictive Accident Risk Modelling
A Poisson regression (or negative binomial for overdispersed data) enhanced with spatial features:
Features per 500m road segment:
traffic_volume_aadt
heavy_vehicle_pct
road_geometry_score (curvature, gradient, sight distance)
access_density (intersections + median openings per km)
pedestrian_activity_index (proximity to villages, bus stops, markets)
lighting_index (lit/unlit/partially lit)
median_type (raised/flush/none/wire rope barrier)
shoulder_condition (paved/unpaved/absent)
speed_differential (85th percentile speed - speed limit)
historical_accident_rate (3-year normalized)
Output: expected_accidents_per_year (with severity distribution)The model identifies high-risk segments that have not yet accumulated 5+ accidents (the IRC threshold) but have the geometric and traffic characteristics of black spots. On NH-48 (Mumbai-Pune Expressway), the model identified 12 segments that met the risk threshold but not the historical accident threshold — 8 of these had their first fatal accident within the following 2 years.
Countermeasure Cost-Effectiveness
The real value is not just identifying black spots — it is prioritizing interventions by benefit-cost ratio:
| Countermeasure | Typical Cost (₹ lakh/km) | Expected Crash Reduction | B/C Ratio |
|---|---|---|---|
| Rumble strips at curves | 2-5 | 15-25% | 8-15 |
| Solar-powered blinkers | 3-8 | 10-20% | 5-10 |
| Median wire rope barrier | 15-25 | 40-60% (head-on) | 4-8 |
| Pedestrian underpass | 80-150 | 60-80% (pedestrian) | 2-5 |
| Realignment (curve correction) | 200-500 | 30-50% | 1-3 |
The optimization model allocates a fixed annual safety budget (say ₹50 crore for a state NH network) across black spots and countermeasure types to maximize total expected accident reduction. Linear programming with the predicted accident reduction as the objective and budget + physical feasibility as constraints.
Indian Traffic Mix Considerations
Two-wheelers account for 35-40% of road fatalities but are underrepresented in standard accident models (which focus on vehicle-vehicle crashes). A separate model for two-wheeler accidents incorporates:
Key Takeaways
This is chapter 4 of AI for Civil & Infrastructure.
Get the full hands-on course — free during early access. Build the complete system. Your projects become your portfolio.
View course details