Loading presentation...

Present Remotely

Send the link below via email or IM

Copy

Present to your audience

Start remote presentation

  • Invited audience members will follow you as you navigate and present
  • People invited to a presentation do not need a Prezi account
  • This link expires 10 minutes after you close the presentation
  • A maximum of 30 users can follow your presentation
  • Learn more about this feature in our knowledge base article

Do you really want to delete this prezi?

Neither you, nor the coeditors you shared it with will be able to recover it again.

DeleteCancel

Make your likes visible on Facebook?

Connect your Facebook account to Prezi and let your likes appear on your timeline.
You can change this under Settings & Account at any time.

No, thanks

Tulsa Transit Project

An update on the Tulsa Web Dev's efforts to get Tulsa Transit data into Google Maps.
by

John Whitlock

on 12 October 2012

Comments (0)

Please log in to add your comment.

Report abuse

Transcript of Tulsa Transit Project

Tulsa Transit Project Getting Tulsa's Buses into Google Maps August 8, 2011 John Whitlock http://tulsawebdevs.org http://github.com/tulsawebdevs/tulsa-transit-google Move Tulsa Forward Catch up with OKC Volunteer without Getting Dirty Meet Other Developers Our Motivations Drink Beer and Write Code Build community in Tulsa Add to Resume Find Work Learn new skills Do something cool http://www.flickr.com/photos/davidburn/3108266391/ http://www.flickr.com/photos/rickie22/1394310802/lightbox/ http://www.flickr.com/photos/lazytom/115460931/ http://www.flickr.com/photos/joelplutchak/3502964278 IT WORKS! Bibiana McHugh IT Manager, GIS, TriMet Involved in Portland GIS community
Why isn't planning a public transit trip as easy as planning a car trip?
In 2005, reached out to Mapquest, Yahoo!, and Google
Only Google responded... Working on a 20% project to put public transit data in Google Maps
Had trouble getting the data
Options were to buy, scrape, or make Freedom of Information Act requests and wait months. Chris Harrelson Software Developer, Google Tulsa Transit Project January
February
March
April
May
June
July
August
September
October
November
December 2011 Decided to make Tulsa Transit the first project First Hack Day
Tried scraping Tulsa Transit website
Planned a GIS data gathering app Jeremy Luttrell offered official data!
...which eventually got out of the mail server First attempts at reading DBF files into a database Second Hack Day
Jeremy Satterfield gets data out of DBF, into GTFS .txt files
We need schedule data! We get schedule data!
Third Hack Day
We get a valid transit feed!
Clean-up work, disable inactive stops John makes a whole bunch of people motion sick with slide transitions The Data GTFS DBFs Schedules feed.zip stops.dbf pattern.dbf stopsByPattern.dbf nodesByLine.dbf nodesByPattern.dbf 22 = 5 + 17 313 = 64 + 249 291 = 60 + 231 313 = 64 + 249 138 = 41 + 97 5 columns useful useless used Stops and geo-location lines.dbf 97 = 18 + 79 4 columns useful useless used AKA routes stopsByLine.dbf 291 = 61 + 230 5 columns useful useless used Connect Stops to Lines 101_1.txt 101_1.txt 101_1.txt runtimes trips stoptrips + 21 + 21 + 21 agency.txt routes.txt trips.txt calendar.txt stop_times.txt frequencies.txt stops.txt fare_rules.txt fare_
attributes.txt calendar_dates.txt transfers.txt shapes.txt General Transit Feed Specification 3 + 3 required optional agency_name
agency_url
agency_timezone agency_id
agency_lang
agency_phone 4 + 5 3 + 5 4 + 0 5 + 0 1 + 4 4 + 1 5 + 4 4 + 6 3 + 1 3 + 0 10 + 0 Demo Time! Check out the code
Enter the virtualenv
Get Transit Data
Run ./parser.py
Validate output
View the schedule Python Rocks Project Organization Transit data goes in input
GTFS appears in output
Google's Transit Tools in transitfeed-1.2.7
parser.py does everything
dbf_parser.py
trip_parser.py
analyze_dbf.py Useful built-ins like dict
Functions are object
Lambdas
Iterations everywhere
'with' for safe processing Batteries Included Awesome Libraries dbf_py
simplejson
pep8
pytz
virtualenv
virtualenvwrapper
transitfeed csv
getopt
glob
os
shutil
sqlite3
sys
zipfile baseHTTPServer
bisect
codecs
datetime
mimetypes
optparse
re
signal
socket
time
urllib
urllib2
webbrowser We used: Google Used: And now, some slides Finish the Project Fix validation warnings
Get more schedule data
Use more of existing data
Get on the web
Design a workflow
Sign paperwork
Beta period
Publish and Celebrate Follow Portland Live transit data
Portland Maps
Civic Apps
Caligator What's Next? Get Local! Oct 7: Tulsa Tech Fest
Oct 7 - 8: Tulsa Hackathon
Nov 12-14: Tulsa Startup Weekend
Aug ? - Next Hack Day
??? - Ignite Tulsa 4
??? - Fab Lab Tulsa Questions? http://prezi.com/glei7vpodnku
Full transcript