Skip to content

hackmecharlie/metascope

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Metascope — EXIF Comparison Web Tool

Metascope is a simple, focused Flask web application that lets you upload two or more image files, extracts metadata from each using the command-line exiftool utility, and returns a JSON response showing each file's metadata and which metadata fields differ between files.

Key features

  • Upload two or more images and compare their metadata side-by-side.
  • Uses exiftool to extract robust, detailed metadata for many image formats.
  • Returns a JSON response containing per-file metadata, saved file paths, and a per-file list of metadata fields that differ from the others.

Requirements

  • Python 3.8 or newer
  • Flask
  • exiftool (installed and available in PATH)

Optional (developer helper): Pillow (PIL) if you run legacy helper scripts.

Quick start (Windows PowerShell)

  1. Create and activate a virtual environment
python -m venv .venv
.\.venv\Scripts\Activate.ps1
  1. Install the Python dependency
pip install Flask
  1. Ensure exiftool is installed and on your PATH (download from https://exiftool.org/ if needed).

  2. Start the app

python app.py

Open http://127.0.0.1:5000/ in your browser and use the upload form to select two or more images.

Usage example (API)

Endpoint: POST /upload_and_compare

  • Form field: files (multipart/form-data) — supply two or more image files.

Successful response (example)

{
	"metadata": [
		{"SourceFile": "uploads/img1.jpg", "Model": "Canon ...", "SHA256": "...", "GPSLatitude": 12.34},
		{"SourceFile": "uploads/img2.jpg", "Model": "Canon ...", "SHA256": "...", "GPSLatitude": 56.78}
	],
	"paths": ["uploads/img1.jpg", "uploads/img2.jpg"],
	"diff_indices": {"0": ["GPSLatitude"], "1": ["GPSLatitude"]}
}

This response includes the extracted metadata array, the server-side saved paths, and diff_indices which maps file indexes to lists of metadata fields that differ for that file.

Example curl (POSIX):

curl -F "files=@img1.jpg" -F "files=@img2.jpg" http://127.0.0.1:5000/upload_and_compare

Project layout

  • app.py — Flask application and upload/compare endpoint
  • templates/index.html — basic upload UI
  • static/ — static assets (CSS/JS if any)
  • uploads/ — runtime upload directory (where uploaded images are saved)

About the repository

This repository provides the minimal server and frontend to extract EXIF/metadata with exiftool and compare results across multiple files. It is intended as a small utility or starting point for building richer metadata analysis tools.

License

No license file is included in this repository. Add a LICENSE if you want to make reuse terms explicit.


If you'd like this file saved as README.md (so GitHub shows it automatically on the repo page), tell me and I will rename it for you.

About

File Hash Metadata compare

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published