Photo library clean-up
Thousands of photos. I'm the one who presses delete.
What it is
A tool on my computer that goes through my photo library. It spots duplicates, screenshots and blurry shots, and suggests which album each one belongs in. I review and decide.
Why I built it
My library was full of unsorted photos. I also needed to find my own shots for the video editor. Sorting them by hand was never going to happen.
How it started
It was born the same night as the video editor, 4 to 5 November. To edit, I needed my photos. Once I looked at them, the problem was a different one: thousands of them, in no order.
First scare: most of my photos and videos weren't on the Mac. They only lived in the cloud.
How it was built
It works on a copy of the Photos database. The real library stays untouched.
It sorts them into numbered sheets of 36 photos: people, food, training, travel. It finds duplicates by moment and similarity, and keeps the best of each group. Favourites are off-limits.
Then it shows me a page to review. I mark each photo yes or no. What's approved goes into an album and I delete it myself from Photos. I decide; Claude wrote the tool.
What went wrong
At first it grouped photos of different skies as duplicates. One blue sky looks a lot like another blue sky.
The blurry-photo detector flagged soft portraits and dog photos as blurry. That's why it never deletes: it only suggests a review.
And you can't delete a photo from Apple's library with code. I thought that was a flaw. Now I think it's perfect.
Where it is now
Three batches done, 442 photos gone. I've got 79 maybes left to review, and I still need to decide what each album is for.
I still don't know why the database and the Photos app don't count the same. I note it down and move on. Videos are phase 2.
What I learned
- A tool that can't delete is an advantage, not a limitation.
- The machine suggests and I decide. In that order.
- Automatic detectors get pretty things wrong: a soft portrait looks like a blurry photo.
Built withClaudePythonApple Photos