/py-geo-tutorial

Tutorial of fundamental remote sensing and GIS methodologies using open source software in python

Primary LanguageJupyter NotebookOtherNOASSERTION

Open Source Geoprocessing Tutorial

Creative Commons License

Tutorial of basic remote sensing and GIS methodologies using modern open source software in Python (rasterio, shapely, geopandas, folium, etc). Notebooks cover raster processing, vector analysis, cloud-based tools like Google Earth Engine, a workflow to perform image classification using machine learning classifiers in scikit-learn, and an introduction to handling large array datasets with xarray:

Repo Structure

All chapters are available as jupyter notebooks in the notebooks/ directory or viewable via a normal web browser in HTML:

  1. Introduction [HTML]

  2. The GDAL datatypes and objects [HTML]

  3. Your first vegetation index [HTML]

  4. Visualizing data [HTML]

  5. Vector data - the OGR library [HTML]

  6. Land cover classification [HTML]

  7. Deep Learning for land cover classification [HTML] built to run in Google Colab.

  8. Earth Engine for Oceanographic Time Series Analysis [HTML]

  9. Xarray for handling N-dimensional arrays and advanced visualization with hvplot [HTML]

Some of the things you'll learn:

Raster Operations, Processing, and Visualization

Interactive Shapefile and Raster Visualization

Machine Learning based Satellite Image Classification

Dealing with large datasets and interactive analysis

Setup

Locally

Download

Materials for these lessons are included inside this repository under the notebooks/ directory. If you're not running in Binder I would recommend downloading all of the lesson material at once, instead of downloading individual files.

  • Use git clone https://github.com/patrickcgray/open-geo-tutorial.git to clone the repository

Python Installation

To run the Jupyter Notebooks (formerly known as IPython Notebooks) and follow the tutorial locally, you will need to install Python and the libraries used in the tutorials. This installation can be accomplished in many ways, but I recommend Docker:

Docker

I highly recommend trying out Docker if you're not familiar with it. There is a bit of a startup time just for getting up to speed but it is the way to go for reproducible work and cloud deployable workflows. Docker provides operating-system-level virtualization, also known as "containerization" and thus you can be sure that your setup precisely replicates the one used here and will easily run everything. Once you've downloaded Docker you can simply cd into the cloned git repo and run:

docker run -it --rm -p 8888:8888 -v <path to repo>:/home/jovyan/repo/ pangeo/pangeo-notebook:2021.05.15 jupyter lab --ip 0.0.0.0

This will download the Docker image that is needed to run this whole repo and then it will start up a Jupyter Lab instance that you can access by clicking the link in the terminal. Just change <path to repo> to the appropriate path and you'll be good to go!

Thanks

patrick gray for the source material: https://github.com/patrickcgray