Skip to content

Instantly share code, notes, and snippets.

View iandees's full-sized avatar
🏠
Working from home

Ian Dees iandees

🏠
Working from home
View GitHub Profile

Learn How to Use OpenStreetMap US Resources

Join us for a 1 hour virtual workshop on how to use OpenStreetMap US server resources.

OpenStreetMap US provides a series of server resources to the OpenStreetMap community free of charge. You can use these servers for jobs that are too large or too long running for your local machine and for cooperating with other community members.

You can see a full list of our servers on our Wiki. These servers offer the following:

  • Full, hourly updated copy of the OpenStreetMap rendering database
  • Latest Mapnik installed and the ability to render and cache arbitrary tile sets
@iandees
iandees / buffer.txt
Created July 12, 2012 13:34
New user log
INFO 2012-07-12T07:02:25 Looking for new users.
ERROR 2012-07-12T07:02:26 Traceback (most recent call last):
File "/home/iandees/supybot/plugins/OSM/plugin.py", line 187, in _minutely_diff_poll
content = urllib2.urlopen(url)
File "/usr/lib/python2.6/urllib2.py", line 126, in urlopen
return _opener.open(url, data, timeout)
File "/usr/lib/python2.6/urllib2.py", line 397, in open
response = meth(req, response)
File "/usr/lib/python2.6/urllib2.py", line 510, in http_response
'http', request, response, code, msg, hdrs)
iandees@benzene:~/tilemill$ mapnik-config --libs
-L/usr/local/lib -lmapnik2
iandees@benzene:~/tilemill$ which mapnik-config
/usr/local/bin/mapnik-config
@iandees
iandees / expire_tiles.py
Created October 8, 2011 03:23
A tool to parse the OSM API's list of expired z12 tiles and delete the corresponding tiles in a TileStache disk cache.
#!/bin/python
import sys
import xml.etree.cElementTree as ET
import urllib2
# Expire tiles in a TileStache default file cache based on the OpenStreetMap server's z12 change output
# at http://www.openstreetmap.org/api/0.6/changes
maxZoom = 19
@iandees
iandees / gist:1215596
Created September 14, 2011 00:53
A script to keep an osm2pgsql database running with minutely diffs and osmosis.
#!/bin/bash
set -e
# Initialize timestamp with day of latest planet dump
# Setting to midnight ensures we get conistent data after first run
# osmosis --read-replication-interval-init
OSMOSIS_PATH=/home/iandees/osmosis-SNAPSHOT-r25995
OSMOSIS_WORKDIR=/home/iandees/.osmosis
OSM2PGSQL_PATH=/home/iandees/osm2pgsql
@iandees
iandees / detect_osm_weirdness.py
Created June 3, 2011 22:05
An OSM "weirdness" detector: Reads minutely/hourly diffs and looks for oddly-shaped ways or ways that don't quite make sense.
#!/bin/python
import sys
import urllib2
import xml.etree.cElementTree as ElementTree
import simplejson as json
from datetime import datetime
import StringIO
import gzip
import time