Hacker News

Help I accidentally a wigglegram

Finding Accidental Wigglegrams

Do you know what a wigglegram is? It is a kind of stereo image you make by looping frames together, like as a GIF. The effect is quite convincing.

I am something of an indecisive photographer. When I like an angle, I will take a lot of frames from slightly different angles, looking for "the shot." And since I am also a bit of a hoarder, I never clear out my camera roll.

"Same shot from different angles"? You know what that sounds a bit familiar. Sure enough, my phone is full of wigglegrams that I took by accident. Years' worth, waiting for me to sit down and stitch them together. Or, perhaps, for something to stitch them together.

The Perceptual Hashing Approach

It occurred to me last weekend that I can use perceptual hashing - what TinEye (et al.) uses for reverse image search - to try and find runs of similar images and pull them out from my library automatically.

So I wrote a little script to hash all my pictures:

Hashing is quick, but downloading photos from iCloud is not. The result is a hash that - unlike a cryptographic function like sha1 - will share more bits with hashes of similar-looking images than with dissimilar ones.

We can use that to calculate the hamming distance between pairs of images and find a threshold:

And extract pairs:

The Results

Hundreds of wigglegrams spew forth. A few of them I am guilty of taking intentionally. But most are true accidents.

As such, many of them come out as less "stereoscopic" and more "kinescopic" - like little unintentional movies.

  • Animals are a natural fit for the concept, unpredictable as they are.
  • Design-work also (I am always indecisive).
  • And sculpture.

What fun.

Try It Yourself

I have the script up on Github if you want to play with it - it'll work on your iCloud photos library if you're on a Mac, or you can point it at a directory of pictures otherwise.

Cheers~

Comments

No comments yet. Start the discussion.