Python can be used to add functionality to QGIS (an open source GIS) and at Land Information New Zealand (LINZ) we have been using increasingly more complex and specialized scripts, tools, and plugins utilising the PyQGIS API to improve how we work. This talk will cover using python to enhance and extend QGIS, using examples of our plugins, and will cover the lessons learnt and useful resources.
This presentation is an overview of how python has been used to add functionality to QGIS (an open source GIS, Geographical Information System). In the Topography (mapping) team at Land Information New Zealand (LINZ) we have been using increasingly more complex and specialized scripts, tools, and plugins written in python utilising the PyQGIS API to improve how we work. I will cover a brief intro to who I am and my role at LINZ. This talk will cover how python can be used to enhance and extend QGIS, as well as the benefits which we have seen from the added functionality and automation which python allows. A brief outline of the core ways the PyQGIS API is used to load layers, manipulate geometry, modify the map canvas and layer symbology, and connect to a POSTGRES database. This will be a quick run through of how the API lets you do anything you wish to do in a normal QGIS session, but with added control, and how this added control increases functionality and allows automation. I will show a sample script with some quick geometry manipulation, layer styling and process algorithms, and describe three ways of using python inside of QGIS; the python console, processing scripts and plugins. I will use examples of scripts and plugins which have been created at LINZ to demonstrate the benefits and show how easy it is to use python to enhance QGIS. In particular, I will give an overview of a quality assurance plugin we have created which demonstrates the evolution of a plugin from simpler processing scripts to a framework using a plugin which ties them together, simplifying the process for a user and adding automation to improve work. I will describe our learnings, and finish with useful resources for those wishing to start out on this journey. This presentation is aimed at those with a basic knowledge of GIS but will focus on the PyQGIS side of our current work so will be appropriate for novice python users.