Book Image

Geospatial Development By Example with Python

By : Pablo Carreira
5 (1)
Book Image

Geospatial Development By Example with Python

5 (1)
By: Pablo Carreira

Overview of this book

From Python programming good practices to the advanced use of analysis packages, this book teaches you how to write applications that will perform complex geoprocessing tasks that can be replicated and reused. Much more than simple scripts, you will write functions to import data, create Python classes that represent your features, and learn how to combine and filter them. With pluggable mechanisms, you will learn how to visualize data and the results of analysis in beautiful maps that can be batch-generated and embedded into documents or web pages. Finally, you will learn how to consume and process an enormous amount of data very efficiently by using advanced tools and modern computers’ parallel processing capabilities.
Table of Contents (17 chapters)
Geospatial Development By Example with Python
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Summary


In this chapter, we saw that the different types of relationships between geometries can be tested, and that these tests can be used in the program to solve problems.

In order to filter by polygons, first we used the same code to import these polygons into the system like we did with the points, but this time we used Shapely to abstract the geometries of the polygons and points. Finally, we used geometry relationships to search for points inside the polygons.

Then, we implemented a way to filter the data by the name property and we made it filter the data by any property of the object or any combination of properties.

Finally, we adapted the app class to work with the new changes and saw that it's possible to add convenience methods to it in order to simplify some tasks.

In the next chapter, we will start working on the Map Maker App and create means to visualize our data.