Python GPS Extract Mapping Script

About the script

Discover the ease of mapping your memories with my Python Extraction Script! This handy tool quickly turns a Windows folder into a HTML map, marking the GPS locations of your photos. It's a simple, efficient way to visualize and share your photo locations.

First: what is Python?

Python is a versatile and user-friendly programming language known for its readability and simplicity, making it an excellent choice for beginners and experts alike. To use a Python script, you'll need to install Python on your computer, which is a straightforward process available on the official Python website. Once installed, you can run Python scripts using a command prompt or a Python IDE (Integrated Development Environment), which offers a more interactive and user-friendly interface. With its extensive libraries and community support, Python is an ideal language for various applications, from data analysis to web development.

Usage of the script

The script is called map.py. For added convenience, I have also provided a map.cmd file, making it simple to run the script from any location in Windows. Here's how you can use it:

Using map.cmd in Command Prompt

  1. Open Command Prompt: Search for 'CMD' or 'Command Prompt' in the Windows search bar.
  2. Navigate to Your Photo Folder: Use the cd command to change to the directory containing your photos.
  3. Run the Script: Type map.cmd and press Enter. The script will then generate your HTML map.

Using map.cmd in Windows Explorer

  1. Open Your Photo Folder: Navigate to the folder where your photos are stored using Windows Explorer.
  2. Access the Address Bar: Click on the address bar at the top of the Windows Explorer window.
  3. Run the Script: Type map.cmd into the address bar and press Enter. This will execute the script and create your map.

system requirements

To begin working with the Python script, it's essential to have the Python environment installed on your computer. You can easily download and install Python from its official website.

This script requires the use of the Folium and Pillow libraries. To install these libraries, open a command prompt on Windows and enter the following commands:

pip install pillow

pip install folium

Additionally, the script includes a convenience feature: a file named map.cmd. This file facilitates running the script from any location on your computer. To make use of this feature, place the map.cmd file in a directory that is part of the Windows Environment Path variable. This ensures that you can access and run your script from any location on your system. If you're not familiar with modifying the Path variable, here is a short description:

For Windows 10:

  1. Search for System Properties:
    • Right-click on the Start button and select "System".
    • Click on "Advanced system settings" on the left side.
  2. Access Environment Variables:
    • In the System Properties window, go to the "Advanced" tab.
    • Click on the "Environment Variables" button near the bottom.
  3. Modify Path Variable:
    • Under "System variables" or "User variables", find and select "Path".
    • Click "Edit".
  4. Add New Location:
    • In the Edit Environment Variable window, click "New".
    • Enter the path of the directory you want to add.
    • Click "OK".
  5. Save and Exit:
    • Click "OK" in the Environment Variables window.
    • Click "OK" again in the System Properties window to close it.

For Windows 11:

  1. Open System Properties:
    • Right-click on the Start button and select "System".
    • Scroll down in the System settings and click on "About".
    • Under "Related settings", click on "Advanced system settings".
  2. Access Environment Variables:
    • In the System Properties window, go to the "Advanced" tab.
    • Click on the "Environment Variables" button.
  3. Modify Path Variable:
    • Locate the "Path" variable under "User variables" or "System variables".
    • Select it and click "Edit".
  4. Add New Location:
    • In the Edit Environment Variable window, click "New".
    • Type or paste the path of the directory you want to add.
    • Click "OK".
  5. Save and Exit:
    • Press "OK" to close the Environment Variables window.
    • Press "OK" again in the System Properties window.

Note: Be cautious when editing the Path variable. Incorrect changes can affect system functionality. The changes will take effect in new command prompt or PowerShell windows. Existing windows will not recognize the changes.

Downloads

Download a ZIP containing both the map.cmd and the map.py files:

pythonMapper.zip
MD5 checksum: 5faae0704bcb69da52a1c54eaf4f4792