Steps from Django to GeoDjango

Within this section, we'll install Django add GeoDjango configurations, and add the required libraries (including the GDAL and OGR) that bring spatial functionality to DjangoInstalling the Django 2 module for Python 3, and configuring the GeoDjango components, depends on a number of steps. These include:

  1. Using pip to install Django 2
  2. Installing and enabling a spatial database (if not already installed)
  3. Installing GDAL/ OGR/PROJ4/GEOS
  4. Configuring the Windows environment variables
  5. Generating a project
  6. Opening settings.py
  7. Adding django.contrib.gis to INSTALLED_APPS
  8. Configuring database settings to point to the spatial database

Get Mastering Geospatial Analysis with Python now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.