python in geoinformatics

17
Python in geoinformatics Marianna Zichar University of Debrecen

Upload: mapwindow-gis

Post on 21-May-2015

429 views

Category:

Software


10 download

DESCRIPTION

Open source technology have became popular in the last years. More and more proprietary software are ready to work with open source applications, what is more they directly support them. A similar situation got me started to use Python, and I really was pleased that this language can be used for many purposes in geoinformatics. Presented by Marianna Zichar, assistant professor, University of Debrecen,

TRANSCRIPT

Page 1: Python in geoinformatics

Python in geoinformaticsMarianna Zichar

University of Debrecen

Page 2: Python in geoinformatics

2

AgendaMotivationThe language (with the main pitfalls)ArcGIS KMLQGISProjectionsVisualizationAnalysis and management of geospatial data

Page 3: Python in geoinformatics

3

The languageGeneral-purpose interpreted, interactive,

high-level programming languageMultiple programming paradigms

Object-orientedImperativeFunctional programmingProcedural

Dynamic language: Scripting Non scripting

Page 4: Python in geoinformatics

4

The languagePython code can be packaged into standalone

executable programsPopular

open sourcelots of tutorials and online resources very active community

Page 5: Python in geoinformatics

5

Main pitfalls of Python Indentation identifies blocks of codeCase sensitivity= is used to assign values== is used to test conditions

Page 6: Python in geoinformatics

6

Python in geoinformatics?YES!

Thousands of different modules and packages are available to extend the functionality of Python containing several ones related to geoinformatics.

Page 7: Python in geoinformatics

7

ArcGIS

Page 8: Python in geoinformatics

8

ArcGISArcgisscripting (ArGIS 9.x)

Arcpy (ArcGIS 10.x)automate geoprocessing tasks manage map documents and layers find and fix broken data linksedit data in feature classes and tables

Page 9: Python in geoinformatics

9

Creating KML filesXML based language to describe features with geospatial information

Simple text file

Modul: xml.dom.minidom

Assuming that you are already familiar with reading shape files or geodatabases you can now write your own function to export data.

Page 10: Python in geoinformatics

10

QGISPython Console

The integrated Python console is ideal for scripting. When the console is started the modules qgis.core and qgis.utils will be imported automatically.

Python PluginsIt is possible to create and use Python plugins to enhance the functionality of QGIS. The plugin installer allows users to easily fetch, upgrade and remove Python plugins.

Python ApplicationsCustom applications can be developed based on QGIS API.

Page 11: Python in geoinformatics

11

Page 12: Python in geoinformatics

12

Page 13: Python in geoinformatics

13

ProjectionsPyproj

”wrapper’” around library called PROJ.4Class: Proj

longitude, latitude native map (x,y) coordinates

Class: Geodperforms various Great Circle distance and angle calculationsnpts() method: calculates the coordinates of a numberof points spaced equidistantlyalong a geodesic line

Page 14: Python in geoinformatics

14

ProjectionsTranslating UTM location into latitude and longitude

Page 15: Python in geoinformatics

15

Visualizing geospatial dataMapnik toolkit: to build mapping applications

Heavily used by OpenStreetMap, because it produces images which are ideal to include in webpages.

Geospatial data from PostGIS database,

shapefile, any other format supported by

GDAL

Clearly rendered images

Page 16: Python in geoinformatics

16

Analyzing and manipulating geospatial dataShapely package for manipulation and analysis of two-dimensional geospatial geometries. Based on the GEOS library.

Page 17: Python in geoinformatics

17

ConclusionDo you maybe know additional packages?

There are several packages which support geoinformatics, and from which I overviewed some, pointing out how useful is to get to know Python language.