Week 4: Raster Data
How do raster grids store geographic information, and how do we locate them on a map?
Week Content
This week introduces raster data through small NumPy arrays before moving to georeferenced GeoTIFFs and real Vienna datasets.
- Raster grids, bands, cell size and spatial resolution
- NoData values, validity masks and raster statistics
- Origins, affine transforms, CRS, bounds and cell coordinates
- Reading and writing GeoTIFFs with Rasterio
- Continuous elevation data and categorical land-cover data
Materials
Lecture slides · PDF Lab notebook · IPYNB Vienna DEM clip · GeoTIFF Vienna WorldCover clip · GeoTIFFLab
Parts A and B reinforce the lecture workflow with a synthetic DEM and a real Vienna elevation raster. Keep the notebook and both GeoTIFF files in the same folder when working in JupyterHub.
Part C is the independent WorldCover exercise. Work through the notebook step by step: inspect metadata, build a valid-cell mask, calculate class counts and shares, identify the most common class, create a categorical map, and then write a short interpretation. Use the separate code cell provided for each stage.
Lab Checkpoint
Save the notebook with your outputs visible. Your WorldCover section should include the requested metadata, class statistics, categorical map, and short interpretation.