Skip to content
DARREN CHEN edited this page Apr 22, 2015 · 6 revisions

Welcome to the StreetSweepingSchedule wiki!

What is the purpose of the StreetSweepingSchedule project?

The python code for this project will parse the street sweeping schedule data into a date field for use in ArcGIS. For example, street sweeping data in San Diego is appears in word strings for use on street signs such as "First and Third Tuesday of every month".

San Diego Street Sweeping Data Sample:

The data used in this project can be found at: http://catalog.opensandiego.org/opendata/search/?sort=name&dir=asc&qs=sweep

Sample unparsed recurring date strings:

*"Not Posted, Both Sides Odd Month 4th Wed" *"Not Posted, Both Sides Even Month 4th Fri" *"Not Posted, Both Sides Odd Month 1st Thu" *"Not Posted, Both Sides Even Month 3rd Thu" *"Posted, Both Sides Odd Month 4th Thu" *"Not Posted, Both Sides Odd Month 1st Thu"

Python Libraries

The libraries that can be used for this code are found here:

List of Natural language parsing code samples (in Github):

http://meta-guide.com/software-meta-guide/100-best-github-natural-language-parsing/

Potential Date Parsing to use for this project:

Recurrent

Recurrent is a python library for natural language parsing of dates and recurring events. It turns strings like >"every tuesday and thurs until next month" into RFC-compliant RRULES, to be fed into a calendar api or python->dateutil's rrulestr. pip install recurrent https://github.com/kvh/recurrent Recurrent Dependency: parsedatetime

parsedatetime

https://github.com/bear/parsedatetime

python-dateutil

https://labix.org/python-dateutil

License