Back to Projects
Personal Project · 2026

Austin Traffic Counts

Millions of rows of raw city traffic-sensor data, turned into clean hourly volumes on real roads and checked against the state’s published counts.

Data EngineeringData QualityPythonDuckDB
Organization
Personal Project
Timeline
2026
Method check
Within 1.9% of TxDOT (median)

Loading the map…

Drag to pan; click the map, then scroll to zoom. On a phone, pinch. Roads, water and towns © OpenStreetMap contributors (ODbL). Traffic: TxDOT and City of Austin. Commuting: U.S. Census Bureau, LEHD Origin-Destination Employment Statistics.

The Challenge

Cities publish years of traffic-sensor data, and almost nobody can use it as published. The City of Austin’s archive has millions of 15-minute counts from radar and cameras, with timestamps that change meaning halfway through, counts that hit a hard ceiling, duplicates, sensors with no location, and no note of any of it. I wanted to show what it takes to turn a public feed like that into something a product or an analyst can trust: one clean table, every row accounted for, and a number that says how far to trust it.

My Approach

I built a pipeline in Python and DuckDB that fetches the data a month at a time and checks every file against the source’s own row count. It flags problems instead of deleting rows, with fifteen rules and their thresholds in one config file, and every clean row traces back to its raw file. It rolls counts up the way each sensor actually measures, links every sensor to an OpenStreetMap road by street name and direction of travel, and then checks the result against independent numbers: FHWA’s hourly counters and TxDOT’s published yearly counts.

By the numbers

6.8 million
raw rows from 19 city sensor sites, every one accounted for
96.7%
usable for traffic volume after cleaning
1.9%
median gap to TxDOT's published counts at 8 permanent counters

Every number on this page is computed by the pipeline from public data and exported to the page. Nothing is typed in by hand.

The data

  • City of Austin radar counts: 6,834,237 rows, one per lane every 15 minutes, from 19 sites, 2017-06-18 to 2021-09-08.
  • FHWA permanent counters: hourly volumes from the federal Travel Monitoring Analysis System, 12 counters in Travis County, 2025.
  • TxDOT yearly counts as the published reference, and OpenStreetMap roads (extract of 2026-12-04) to put every count on a road.

What was wrong with it

None of this is in the documentation. Each one turned up because the pipeline checks the data against itself before trusting it.

2017-06: data present2017-07: data present2017-08: data present2017-09: data present2017-10: data present2017-11: data present2017-12: data present2018-01: data present2018-02: data present2018-03: data present2018-04: data present2018-05: data present2018-06: data present2018-07: data present2018-08: data present2018-09: data present2018-10: data present2018-11: data present2018-12: data present2019-01: data present2019-02: data present2019-03: data present2019-04: data present2019-05: data present2019-06: data present2019-07: data present2019-08: data present2019-09: data present2019-10: data present2019-11: data present2020-04: data present2020-05: data present2020-06: data present2020-07: data present2020-08: data present2020-09: data present2020-10: data present2020-11: data present2020-12: data present2021-01: data present2021-02: data present2021-03: data present2021-04: data present2021-05: data present2021-06: data present2021-07: data present2021-08: data present2021-09: data present2017-06: 0.0% of 3,928 rows2017-07: 0.0% of 30,018 rows2017-08: 0.0% of 71,470 rows2017-09: 0.0% of 179,265 rows2017-10: 0.0% of 214,735 rows2017-11: 0.0% of 173,876 rows2017-12: 0.0% of 167,039 rows2018-01: 0.0% of 162,188 rows2018-02: 0.0% of 177,377 rows2018-03: 0.0% of 210,078 rows2018-04: 0.0% of 228,528 rows2018-05: 0.0% of 198,988 rows2018-06: 0.0% of 204,786 rows2018-07: 0.0% of 238,176 rows2018-08: 0.0% of 95,397 rows2018-09: 0.0% of 163,289 rows2018-10: 0.0% of 219,285 rows2018-11: 0.0% of 149,916 rows2018-12: 0.0% of 150,394 rows2019-01: 0.0% of 135,593 rows2019-02: 0.0% of 134,883 rows2019-03: 0.1% of 185,418 rows2019-04: 100.0% of 144,952 rows2019-05: 100.0% of 175,306 rows2019-06: 100.0% of 149,902 rows2019-07: 100.0% of 176,979 rows2019-08: 100.0% of 183,980 rows2019-09: 100.0% of 178,476 rows2019-10: 100.0% of 139,948 rows2019-11: 100.0% of 98,897 rows2020-04: 100.0% of 149,700 rows2020-05: 100.0% of 152,576 rows2020-06: 100.0% of 154,542 rows2020-07: 100.0% of 158,934 rows2020-08: 100.0% of 130,345 rows2020-09: 100.0% of 117,401 rows2020-10: 100.0% of 133,833 rows2020-11: 100.0% of 100,155 rows2020-12: 100.0% of 118,082 rows2021-01: 100.0% of 123,664 rows2021-02: 100.0% of 90,359 rows2021-03: 100.0% of 108,818 rows2021-04: 100.0% of 103,258 rows2021-05: 100.0% of 98,921 rows2021-06: 100.0% of 110,657 rows2021-07: 100.0% of 113,567 rows2021-08: 100.0% of 100,240 rows2021-09: 100.0% of 26,118 rows20172018201920202021100%0%
Share of each month’s radar rows whose UTC timestamp contradicts the local date columns. The column is right until early 2019, lands near 1970 for most of 2019, and from April 2020 holds local time labelled as UTC. The strip under the axis marks months with data; gaps are months with none. The local columns give the same daily traffic shape throughout, so the pipeline uses them.
240 vehicles: 3,252 rows241 vehicles: 3,142 rows242 vehicles: 3,150 rows243 vehicles: 2,957 rows244 vehicles: 2,981 rows245 vehicles: 2,958 rows246 vehicles: 2,876 rows247 vehicles: 2,868 rows248 vehicles: 2,802 rows249 vehicles: 2,807 rows250 vehicles: 2,676 rows251 vehicles: 2,577 rows252 vehicles: 2,599 rows253 vehicles: 2,533 rows254 vehicles: 2,457 rows255 vehicles: 2,464 rows256 and up:never reported2402452502552603,2520
Radar rows reporting 240 to 264 vehicles in one lane in 15 minutes. Counts thin out smoothly and stop dead at 255: 36 of 86 detectors reach 255 and none ever goes higher. That’s the largest number one byte holds, so busy lanes may be undercounted.
Highway speeds on city streets
514,862 radar rows report average speeds over 100 mph, up to 158 mph. They average 1.39 vehicles per 15 minutes: one stray reading in an empty lane. The speed is flagged; the count is kept.
The same reading twice
Detector 1 reports 132 vehicles at 2017-08-01 17:15:00 twice, under two different row IDs. Exact duplicates are flagged rather than silently collapsed, so the count of them is part of the record.
Data before the data starts
The city says the radar archive begins in December 2017. The rows begin on 2017-06-18.
Federal files that aren't there
On FHWA’s download page, all 65 files for 2020 to 2024 return the same 15,652-byte “file not found” page, saved with a .zip name. Only 2025 is real. Its station list has 2 counters “established” in 2039, and lists the same counters under two ID formats.

How the pipeline handles it

  1. Fetch one month at a time. Each file is checked against the portal’s own row count and fingerprinted, so a rerun skips what it already has and a short download fails loudly.
  2. Flag, never delete. Fifteen rules, each with a threshold in one config file. A row with no flags is usable; a wrong speed or label keeps the count usable. Rows in always equals rows out.
  3. Trace every row. Each clean row carries the raw file and record ID it came from.
  4. Roll up by what the hardware measures. Radar lanes add up to a two-way road total; camera movements add up to the traffic entering from each approach.
  5. Put it on the map. 50 of 51 sensor directions link to an OpenStreetMap road, matched on street name and direction of travel.
  6. Check it against someone else’s numbers before calling it clean.
UTC timestamp contradicts the local time: 3,339,762 rows (48.87%)UTC timestamp contradicts the local time48.9%Lane with no direction recorded: 582,194 rows (8.52%)Lane with no direction recorded8.5%Average speed over 100 mph: 514,862 rows (7.53%)Average speed over 100 mph7.5%Sensor missing from the city’s location lists: 139,206 rows (2.04%)Sensor missing from the city’s location lists2.0%Sensor reads zero for 4+ daytime hours: 58,275 rows (0.85%)Sensor reads zero for 4+ daytime hours0.85%Not a clean 15-minute bin: 56,899 rows (0.83%)Not a clean 15-minute bin0.83%Exact duplicate row: 9,074 rows (0.13%)Exact duplicate row0.13%Same time, conflicting counts: 7,236 rows (0.11%)Same time, conflicting counts0.11%Count of exactly 255: 2,464 rows (0.04%)Count of exactly 2550.04%
Rows carrying each flag, out of 6,834,237. Filled bars make a row’s count unusable; hollow, dashed bars mark a wrong label or speed, so the count itself is kept. A row can carry several flags.

Does it hold up?

Two separate questions. First, is the method right? Turning FHWA’s hourly counts into yearly averages the standard way lands a median 1.9% from what TxDOT publishes for the same counters. Second, is the city data right? The city radar reads a median 26.2% below the nearest TxDOT station on the same street, across 7 site-years. The two count at different points on the street, so some gap is expected; a consistent shortfall fits the 255 ceiling and is worth knowing before anyone builds on these counts.

Method: FHWA vs TxDOTData: city radar vs TxDOTCity radar, South Lamar Boulevard 2019: 30,596 vs TxDOT 45,516 (-32.8%)City radar, South Lamar Boulevard 2017: 30,048 vs TxDOT 42,922 (-30%)City radar, Burnet Road 2018: 23,575 vs TxDOT 33,660 (-30%)City radar, East Cesar Chavez Street 2018: 22,608 vs TxDOT 30,614 (-26.2%)City radar, Burnet Road 2019: 23,809 vs TxDOT 31,251 (-23.8%)City radar, South Lamar Boulevard 2018: 30,224 vs TxDOT 36,688 (-17.6%)FHWA 0000S4 (0.3 MILES SOUTH OF FM1626, S. AUSTIN): 120,611 vs TxDOT 136,795 (-11.8%)FHWA 00S216 (4.2 MILES WEST OF FM 1826, AUSTIN): 33,705 vs TxDOT 37,962 (-11.2%)FHWA 00S131 (3.3 MILES SOUTH OF SH 71, AUSTIN): 36,117 vs TxDOT 36,974 (-2.3%)FHWA 00S253 (SH 130, 0.5 MILE NORTH OF FM 812): 46,768 vs TxDOT 46,911 (-0.3%)FHWA 00S397 (0.5 MILE SOUTH OF WILLIAM CANNON DRIV): 85,232 vs TxDOT 85,322 (-0.1%)FHWA 00S284 (SH 45, 2.3 MILES EAST OF IH 35): 25,698 vs TxDOT 25,704 (0%)FHWA 00S241 (0.9 MILE NORTH OF BRAKER LANE): 121,105 vs TxDOT 119,408 (+1.4%)City radar, East Cesar Chavez Street 2019: 31,979 vs TxDOT 30,614 (+4.5%)FHWA 00S132 (NORTH OF TOWN LAKE BRIDGE, AUSTIN): 189,623 vs TxDOT 143,558 (+32.1%)−40%−30%−20%−10%0%+10%+20%+30%+40%
Difference from TxDOT’s published annual average daily traffic. Top row, filled: FHWA’s hourly counts turned into a yearly average by this pipeline, at the same counters TxDOT publishes. Bottom row, hollow: the city’s radar against the nearest TxDOT station on the same street. Shaded: ±5%.

What the clean data shows

City radar, 18 arterial sites, 00:00: 1.0% of the dayCity radar, 18 arterial sites, 01:00: 0.6% of the dayCity radar, 18 arterial sites, 02:00: 0.4% of the dayCity radar, 18 arterial sites, 03:00: 0.3% of the dayCity radar, 18 arterial sites, 04:00: 0.3% of the dayCity radar, 18 arterial sites, 05:00: 0.6% of the dayCity radar, 18 arterial sites, 06:00: 1.9% of the dayCity radar, 18 arterial sites, 07:00: 4.3% of the dayCity radar, 18 arterial sites, 08:00: 5.7% of the dayCity radar, 18 arterial sites, 09:00: 5.8% of the dayCity radar, 18 arterial sites, 10:00: 5.5% of the dayCity radar, 18 arterial sites, 11:00: 5.8% of the dayCity radar, 18 arterial sites, 12:00: 6.7% of the dayCity radar, 18 arterial sites, 13:00: 6.9% of the dayCity radar, 18 arterial sites, 14:00: 6.7% of the dayCity radar, 18 arterial sites, 15:00: 6.9% of the dayCity radar, 18 arterial sites, 16:00: 7.1% of the dayCity radar, 18 arterial sites, 17:00: 7.2% of the dayCity radar, 18 arterial sites, 18:00: 7.1% of the dayCity radar, 18 arterial sites, 19:00: 6.1% of the dayCity radar, 18 arterial sites, 20:00: 4.6% of the dayCity radar, 18 arterial sites, 21:00: 3.7% of the dayCity radar, 18 arterial sites, 22:00: 2.8% of the dayCity radar, 18 arterial sites, 23:00: 1.9% of the dayFHWA permanent counters, 12 highway sites, 00:00: 1.0% of the dayFHWA permanent counters, 12 highway sites, 01:00: 0.7% of the dayFHWA permanent counters, 12 highway sites, 02:00: 0.6% of the dayFHWA permanent counters, 12 highway sites, 03:00: 0.6% of the dayFHWA permanent counters, 12 highway sites, 04:00: 1.1% of the dayFHWA permanent counters, 12 highway sites, 05:00: 2.7% of the dayFHWA permanent counters, 12 highway sites, 06:00: 4.9% of the dayFHWA permanent counters, 12 highway sites, 07:00: 6.2% of the dayFHWA permanent counters, 12 highway sites, 08:00: 6.1% of the dayFHWA permanent counters, 12 highway sites, 09:00: 5.8% of the dayFHWA permanent counters, 12 highway sites, 10:00: 5.6% of the dayFHWA permanent counters, 12 highway sites, 11:00: 5.7% of the dayFHWA permanent counters, 12 highway sites, 12:00: 5.9% of the dayFHWA permanent counters, 12 highway sites, 13:00: 6.0% of the dayFHWA permanent counters, 12 highway sites, 14:00: 6.2% of the dayFHWA permanent counters, 12 highway sites, 15:00: 6.3% of the dayFHWA permanent counters, 12 highway sites, 16:00: 6.4% of the dayFHWA permanent counters, 12 highway sites, 17:00: 6.3% of the dayFHWA permanent counters, 12 highway sites, 18:00: 5.9% of the dayFHWA permanent counters, 12 highway sites, 19:00: 4.8% of the dayFHWA permanent counters, 12 highway sites, 20:00: 3.9% of the dayFHWA permanent counters, 12 highway sites, 21:00: 3.2% of the dayFHWA permanent counters, 12 highway sites, 22:00: 2.5% of the dayFHWA permanent counters, 12 highway sites, 23:00: 1.7% of the day00:0006:0012:0018:0023:000%4%
Weekday traffic by hour, as a share of the day’s total. Solid: City radar, 18 arterial sites. Dashed: FHWA permanent counters, 12 highway sites. The highways fill up earlier in the morning; the city arterials carry more of their day in the afternoon and evening.

Where the roads are filling up

The city’s sensors cover a few corridors; TxDOT’s published counts cover most major roads in the county. Comparing each road’s traffic with a rough capacity (its lanes times a planning figure per lane) and with its own trend since 2010 gives a screen: 87 km of major road is already full and still growing, 249 km is full with no clear growth, and 162 km is on course to fill by 2035.

Getting there meant catching three more problems: stations that count a whole freeway landing on the express lane beside it, a station whose count jumped fourfold in one year because it had been redefined, and one-direction counts compared with both directions’ lanes. Each now has a rule and a threshold in the config. It’s a screen of where to look, not a forecast of what to build: a road already at capacity can’t show growth in its counts.

Who’s on them

Counts show where cars are, not where trips start and end. The Census’s home-to-work records fill that in: working residents of the five-county metro went from 859,741 to 1,211,275 between 2014 and 2024, and jobs from 888,816 to 1,335,677. Along the worst corridors the growth is sharper: commutes lined up with North Mopac Expressway’s full stretch rose 30%, and with Hamilton Pool Road’s, 131%.

Sources

Data: Austin Transportation and Public Works, City of Austin, Texas Open Data Portal (public domain); Federal Highway Administration, Travel Monitoring Analysis System; Texas Department of Transportation; U.S. Census Bureau, LEHD Origin-Destination Employment Statistics. Roads, water and towns © OpenStreetMap contributors (ODbL). Not endorsed by the City of Austin, FHWA or TxDOT.

Impact

Every raw row accounted for: rows in equals rows usable plus rows flagged, per source and year
Found and handled defects the publisher doesn’t document, including a timestamp column that changes meaning twice and a radar count that never exceeds 255
The averaging method lands a median 1.9% from TxDOT’s published counts at FHWA’s permanent counters
Showed the city radar reads well below TxDOT on the same streets, which anyone building on these counts needs to know

Technologies

Python 3.12DuckDBGeoPandas / ShapelypyosmiumOpenStreetMappytest