Lesson 6: EXIF Data

Photos taken in space are useless if we don't know WHERE they were taken. We use EXIF metadata to store the location directly inside the image file.

Session Goals
  • Understand Metadata and EXIF tags.
  • Use the exif library to read/write tags.
  • Combine ISS Location data with images.

The Mission Task

Scientists need to match each photo with the exact location of the ISS at that moment. We will automate this process by "geotagging" our images.

Key Concepts

Metadata
Data about data. For images, this includes camera settings, time, and location.
EXIF
Exchangeable Image File Format. The standard for storing metadata in JPEG images.
Geotagging
The process of adding geographical identification metadata (latitude/longitude) to media.

EXIF Library

Tools for reading and writing image metadata.

from exif import Image
UsageDescription
img = Image(file)Load an image object.
img.gps_latitude = valSet the latitude tag.
img.list_all()List all current tags.

Astro Pi Orbit

Provides information about the ISS orbit and position.

from astro_pi_orbit import ISS
UsageDescription
iss = ISS()Initialize the ISS interface.
iss.get_position()Returns an object with .latitude and .longitude.

Mission Control Interface

Output Terminal
Ready to execute...