Book description
Create and manage spatial data with PostGIS
About This Book
- Import and export geographic data from the PostGIS database using the available tools
- Maintain, optimize, and fine-tune spatial data for long-term viability
- Utilize the parallel support functionality that was introduced in PostgreSQL 9.6
Who This Book Is For
This book is for developers who need some quick solutions for PostGIS. Prior knowledge of PostgreSQL and spatial concepts would be an added advantage.
What You Will Learn
- Import and export geographic data from the PostGIS database using the available tools
- Structure spatial data using the functionality provided by a combination of PostgreSQL and PostGIS
- Work with a set of PostGIS functions to perform basic and advanced vector analyses
- Connect PostGIS with Python
- Learn to use programming frameworks around PostGIS
- Maintain, optimize, and fine-tune spatial data for long-term viability
- Explore the 3D capabilities of PostGIS, including LiDAR point clouds and point clouds derived from Structure from Motion (SfM) techniques
- Distribute 3D models through the Web using the X3D standard
- Use PostGIS to develop powerful GIS web applications using Open Geospatial Consortium web standards
- Master PostGIS Raster
In Detail
PostGIS is a spatial database that integrates the advanced storage and analysis of vector and raster data, and is remarkably flexible and powerful. PostGIS provides support for geographic objects to the PostgreSQL object-relational database and is currently the most popular open source spatial databases.
If you want to explore the complete range of PostGIS techniques and expose related extensions, then this book is for you.
This book is a comprehensive guide to PostGIS tools and concepts which are required to manage, manipulate, and analyze spatial data in PostGIS. It covers key spatial data manipulation tasks, explaining not only how each task is performed, but also why. It provides practical guidance allowing you to safely take advantage of the advanced technology in PostGIS in order to simplify your spatial database administration tasks. Furthermore, you will learn to take advantage of basic and advanced vector, raster, and routing approaches along with the concepts of data maintenance, optimization, and performance, and will help you to integrate these into a large ecosystem of desktop and web tools.
By the end, you will be armed with all the tools and instructions you need to both manage the spatial database system and make better decisions as your project's requirements evolve.
Style and approach
This comprehensive guide uses a problem-solving approach to help you acquire a solid understanding of PostGIS.
Publisher resources
Table of contents
- Title Page
- Copyright and Credits
- Packt Upsell
- Contributors
- Preface
-
Moving Data In and Out of PostGIS
- Introduction
- Importing nonspatial tabular data (CSV) using PostGIS functions
- Importing nonspatial tabular data (CSV) using GDAL
- Importing shapefiles with shp2pgsql
- Importing and exporting data with the ogr2ogr GDAL command
- Handling batch importing and exporting of datasets
- Exporting data to a shapefile with the pgsql2shp PostGIS command
- Importing OpenStreetMap data with the osm2pgsql command
- Importing raster data with the raster2pgsql PostGIS command
- Importing multiple rasters at a time
- Exporting rasters with the gdal_translate and gdalwarp GDAL commands
- Structures That Work
- Working with Vector Data – The Basics
-
Working with Vector Data – Advanced Recipes
- Introduction
- Improving proximity filtering with KNN
- Improving proximity filtering with KNN – advanced
- Rotating geometries
- Improving ST_Polygonize
- Translating, scaling, and rotating geometries – advanced
- Detailed building footprints from LiDAR
- Creating a fixed number of clusters from a set of points
- Calculating Voronoi diagrams
-
Working with Raster Data
- Introduction
- Getting and loading rasters
- Working with basic raster information and analysis
- Performing simple map-algebra operations
- Combining geometries with rasters for analysis
- Converting between rasters and geometries
- Processing and loading rasters with GDAL VRT
- Warping and resampling rasters
- Performing advanced map-algebra operations
- Executing DEM operations
- Sharing and visualizing rasters through SQL
- Working with pgRouting
-
Into the Nth Dimension
- Introduction
- Importing LiDAR data
- Performing 3D queries on a LiDAR point cloud
- Constructing and serving buildings 2.5D
- Using ST_Extrude to extrude building footprints
- Creating arbitrary 3D objects for PostGIS
- Exporting models as X3D for the web
- Reconstructing Unmanned Aerial Vehicle (UAV) image footprints with PostGIS 3D
- UAV photogrammetry in PostGIS – point cloud
- UAV photogrammetry in PostGIS – DSM creation
-
PostGIS Programming
- Introduction
- Writing PostGIS vector data with Psycopg
- Writing PostGIS vector data with OGR Python bindings
- Writing PostGIS functions with PL/Python
- Geocoding and reverse geocoding using the GeoNames datasets
- Geocoding using the OSM datasets with trigrams
- Geocoding with geopy and PL/Python
- Importing NetCDF datasets with Python and GDAL
-
PostGIS and the Web
- Introduction
- Creating WMS and WFS services with MapServer
- Creating WMS and WFS services with GeoServer
- Creating a WMS Time service with MapServer
- Consuming WMS services with OpenLayers
- Consuming WMS services with Leaflet
- Consuming WFS-T services with OpenLayers
- Developing web applications with GeoDjango – part 1
- Developing web applications with GeoDjango – part 2
- Developing a web GPX viewer with Mapbox
-
Maintenance, Optimization, and Performance Tuning
- Introduction
- Organizing the database
- Setting up the correct data privilege mechanism
- Backing up the database
- Using indexes
- Clustering for efficiency
- Optimizing SQL queries
- Migrating a PostGIS database to a different server
- Replicating a PostGIS database with streaming replication
- Geospatial sharding
- Paralellizing in PosgtreSQL
- Using Desktop Clients
- Introduction to Location Privacy Protection Mechanisms
- Other Books You May Enjoy
Product information
- Title: PostGIS Cookbook - Second Edition
- Author(s):
- Release date: March 2018
- Publisher(s): Packt Publishing
- ISBN: 9781788299329
You might also like
book
Designing Data-Intensive Applications
Data is at the center of many challenges in system design today. Difficult issues need to …
audiobook
The Design of Everyday Things
First, businesses discovered quality as a key competitive edge; next came science. Now, Donald A. Norman, …
book
Python Geospatial Development - Third Edition
Develop sophisticated mapping applications from scratch using Python 3 tools for geospatial development About This Book …
book
Hands-On Machine Learning with Scikit-Learn, Keras, and TensorFlow, 2nd Edition
Through a series of recent breakthroughs, deep learning has boosted the entire field of machine learning. …