Take some time to transcribe PyCon 2014 talks! Click on the "Share" button below the video and then "Subtitle" to get started.
Using Geospatial Data with Python, SciPy2013 Tutorial, Part 3 of 6
Presenter: Kelsey Jordahl
Geographically referenced data is important in many scientific fields, and working with spatial data has become widespread in other domains as well (e.g. Google Maps, geolocated tweets, 4square checkins). Python has become an increasingly important language for working with geospatial data. In this tutorial, students will get experience in working with common geospatial formats in open source python libraries.
Python bindings are available for (nearly) all the standard libraries for working with geospatial data (proprietary and open source). Some of these libraries (including PROJ.4 and GDAL) will be discussed and used in this tutorial, along with more "pythonic" packages for accessing them, such as Shapely. Using spatially-aware databases will be discussed, with examples and an exercise using PostGIS, an extension to PostgreSQL. Python scripting extensions to Geographic Information Systems (GIS) packages such as QGIS and ArcView will be briefly discussed.
This tutorial should be accessible to anyone who has a basic understanding of NumPy and matplotlib. Prior familiarity with SQL database queries and the python DB API will be helpful for the PostGIS section.
1 map projections ~~~~~~~~~~~~~~~~~~ /10 min/
1.1 pyproj /10 min + 15 min exercise/
1.2 baseplot /10 min + 10 min exercise/
1.3 cartopy /5 min/
2 geographical data ~~~~~~~~~~~~~~~~~~~~
2.1 data formats /20 min intro/
2.2 GDAL/OGR /10 min + 10 min exercise/
2.3 Shapely /15 min + 30 min exercise/
/30 min + 30 min exercise/
2.4.1 Connecting to a PostGIS database with psycopg2
2.4.2 Converting latitude and longitude fields to geographical points
2.4.3 Setting and converting coordinate systems
2.4.4 Aggregation and geographic calculations with queries
2.4.5 GEOMETRY and GEOGRAPHY data types
3 plugins for GIS software ~~~~~~~~~~~~~~~~~~~~~~~~~~~
3.1 QGIS /15 min/
3.2 ArcGIS /10 min/
4 Conclusion ~~~~~~~~~~~~~ /10 min/
required packages pyproj, gdal, shapely, psycopg2 optional packages PostGIS, QGIS, cartopy