Live data from Hacker News

The algorithm for a perfectly balanced photo gallery

crispymtn.com

91–100 of 104 posts

Re: The algorithm for a perfectly balanced photo gallery

#91
post #33

Earlier quoted context omitted.

I agree, that looks very nice. I might be wrong here but I think the background is just the picture, although scaled and has got many filters on it.

Actually, you're right! It's the same picture, scaled down to around 500x500 and with a heavy gaussian blur applied to it. The trick is to have a subtle grain effect over it to eliminate gradient artifacts.

Are these generated on-the-fly or when the image is first uploaded?

Re: The algorithm for a perfectly balanced photo gallery

#92
post #53

Side-topic. Shooting Holi [1] without putting your camera in an airtight sealed enclosure is a good way to ruin your equipment. http://en.wikipedia.org/wiki/Holi http://www.lensrentals.com/blog/2013/05/how-to-ruin-your-gea...

If the dust is that invasive into nominally sealed lenses, I really wouldn't want to be breathing the stuff.

depending on the size and make up of the particulate our bodies are actually pretty damn good with removing most particulate, additionally because it is not a regular exposure it is now a smaller risk

Re: The algorithm for a perfectly balanced photo gallery

#93

I've studied this a great deal, and developed a custom masonry type layout to mitigate the row/column bias. I believe it is a much more balanced layout than the article shows. Using it in Imagist, a paid app. Open to a few beta testers for iOS 7 as well, if you want to judge for yourself.

for iOS only or also web?

Re: The algorithm for a perfectly balanced photo gallery

#94
post #53

Side-topic. Shooting Holi [1] without putting your camera in an airtight sealed enclosure is a good way to ruin your equipment. http://en.wikipedia.org/wiki/Holi http://www.lensrentals.com/blog/2013/05/how-to-ruin-your-gea...

Thanks, I was wondering where all the white people in the pictures came from.

Re: The algorithm for a perfectly balanced photo gallery

#95

It like how it looks, but much like Flickr I dislike how it's biased towards landscape pictures. Some of my best photos are portrait, but they get overshadowed by the landscape ones. I imagine the algorithm to cater to both is much harder, because you wouldn't be able to treat each row in isolation, can it actually be solved to a good standard?

If you prefer portaits: use columns instead of rows and scroll horizontally instead of vertically. If you want to avoid the bias you have to try something else: e.g. reorder the images, overlap them, convert to square format…

You can also use free placement, i.e. not restricted to either rows or columns.

Re: The algorithm for a perfectly balanced photo gallery

#96
post #25

btw this breaks zoom.

Not only that it breaks zoom, at certain window ratios (eg: 480x800) is completely fails - I get this error: TypeError: solution[(n - 1)] is undefined @ http://www.chromatic.io/application.a3c7ec1cbcca0f5a77fbc1dc...

I've done stuff like this in the past, if you want something that works: https://github.com/ionelmc/jquery-gp-gallery

Re: The algorithm for a perfectly balanced photo gallery

#97
Interestingly when I load up their demo gallery at: http://www.chromatic.io/FQrLQsb and click on one of the images to enlarge it, then click again to drop back into the gallery view, the gallery breaks horribly (about 1/3 of the images vanish).

FF 22 on Windows 8

Re: The algorithm for a perfectly balanced photo gallery

#98

I've studied this a great deal, and developed a custom masonry type layout to mitigate the row/column bias. I believe it is a much more balanced layout than the article shows. Using it in Imagist, a paid app. Open to a few beta testers for iOS 7 as well, if you want to judge for yourself.

for iOS only or also web?

It was for iOS.

Re: The algorithm for a perfectly balanced photo gallery

#99
post #81

I've studied this a great deal, and developed a custom masonry type layout to mitigate the row/column bias. I believe it is a much more balanced layout than the article shows. Using it in Imagist, a paid app. Open to a few beta testers for iOS 7 as well, if you want to judge for yourself.

Yes, please?

Testflight for iOS 7: http://tflig.ht/WwNYgp

Re: The algorithm for a perfectly balanced photo gallery

#100
post #51

Since I'm a CS theory person, I can offer some theoretical improvements on the running time and make the problem even more general... Instead of minimize the linear difference of partition, we might want to minimize the standard deviation, or basically any convex function, and still do it in the same time bound. One can reduce this problem to find a k-edge path of minimum weight on a complete DAG. The naive algorithm…

a solution would be awesome, especially in javascript. i actually found a case where their linear algorithm, https://github.com/crispymtn/linear-partition, failed.
Post reply on HN