Spectra automatically organizes your image collections by analyzing color, texture, and content similarity. Say goodbye to chaotic folders — let your images flow in visual harmony.
- 🔍 Multi-dimensional visual analysis: Extracts color histograms, spatial patterns, texture features, brightness metrics, and aspect ratio
- 🧩 Smart clustering: Uses DBSCAN algorithm to group visually similar images
- 🔄 Nearest-neighbor sorting: Creates smooth visual transitions within and between clusters
- 🖥️ User-friendly GUI: Clean Tkinter interface—no command line needed
- 🛡️ Safe operations: Dry-run mode and automatic backups protect your files
- 📊 Detailed logging: Real-time progress tracking and CSV mapping of all changes
- ⏱️ Live progress: Stage-by-stage status, item counts, and completion percentage
- ⚙️ Customizable: Adjustable similarity thresholds and filename prefixes
- 💡 Guided controls: Clear similarity-weight descriptions and date-pattern examples
- 📂 Fast handoff: Open the sorted folder and quit Spectra in one action
No Python, PowerShell, or other development tools are required.
- Open the latest Spectra release.
- Download the file ending in
windows-amd64-Setup.exe. - Run the downloaded Setup executable.
- Review the license, choose whether to create a desktop shortcut, and select Install.
- Launch Spectra from the Start Menu, the optional desktop shortcut, or the final Setup page.
Setup installs Spectra for the current Windows user and supports upgrades and uninstall through Windows Installed apps.
After installation, use Extras > Install > Check for Updates to download and open the latest GitHub release Setup executable.
For an installation-free copy, download the file ending in windows-amd64-portable.zip from the latest release, extract the entire archive, and run the Spectra executable inside the extracted folder.
Spectra analyzes each image across multiple dimensions:
- RGB & HSV color histograms: Captures overall color distribution
- Spatial color features: Tracks color placement in a 4×4 grid
- Texture analysis: Detects edges, patterns, and variance
- Brightness & contrast: Measures tonal characteristics
Uses DBSCAN (Density-Based Spatial Clustering) to:
- Group images with similar visual characteristics
- Automatically determine optimal cluster count
- Handle outliers gracefully
- Sorts images within clusters using nearest-neighbor algorithm
- Orders clusters for smooth visual transitions
- Optimizes connections between cluster boundaries
- Renames files sequentially (e.g.,
001.jpg,002.jpg,003.jpg) - Creates backup of originals (optional)
- Generates CSV mapping file for reference
- 📸 Photo collections: Organize vacation photos by scene and color
- 🎨 Design assets: Sort product images, textures, or color palettes
- 🖼️ Digital art: Arrange artwork by style and composition
- 📱 Screenshots: Group similar UI states or app screens
- 🏠 Home organization: Sort scanned documents or family photos
-
Launch Spectra from the Start Menu or desktop shortcut.
-
Select your image folder
- Click "Browse" to choose your image directory
- Supported formats: JPG, JPEG, PNG, BMP, GIF, TIFF, WEBP
-
Configure settings
- File prefix: Add a prefix to sorted filenames (optional)
- Similarity threshold: Lower values = tighter grouping (0.005-0.05 typical)
- Auto-determine: Let Spectra calculate optimal threshold
- Dry run: Preview changes without modifying files
- Create backup: Saves originals to
backup_originals/folder
-
Start sorting
- Click "Start Sorting"
- Monitor progress in the log window
- Review results and mapping file
After processing, Spectra generates:
your-image-folder/
├── sorted_001.jpg # Renamed images in order
├── sorted_002.jpg
├── sorted_003.jpg
├── ...
├── rename_mapping.csv # Original → New name mapping
└── backup_originals/ # Original files (if backup enabled)
├── original_name1.jpg
├── original_name2.jpg
└── ...
Original Name,New Name
"IMG_5234.jpg","sorted_001.jpg"
"DSC_0891.jpg","sorted_002.jpg"
"photo.png","sorted_003.png"| Threshold | Clustering behavior |
|---|---|
| 0.005-0.01 | Very tight—only nearly identical images grouped |
| 0.01-0.02 | Moderate—similar colors and compositions |
| 0.02-0.05 | Loose—broader visual themes |
| Auto | Spectra calculates based on your dataset |
- Processing time: ~0.5-1 second per image (depends on resolution)
- Memory usage: ~50-100MB per 1000 images
- Optimal batch size: Up to 5000 images per folder
- ✅ Dry run mode: Preview all changes before committing
- ✅ Automatic backups: Original files preserved in separate folder
- ✅ Mapping file: CSV log of all filename changes
- ✅ Non-destructive: Images are renamed, never modified
- ✅ Error handling: Skips problematic images with warnings
Contributions are welcome!
This project is licensed under the MIT License - see the LICENSE file for details.
- Built with Pillow for image processing
- Powered by scikit-learn for clustering algorithms
- UI created with Tkinter
Questions? Suggestions? Issues?
Made with ❤️ for photographers, designers, and digital hoarders everywhere
Star ⭐ this repo if you find it useful!

