|
This post originated from an RSS feed registered with Ruby Buzz
by Eigen Class.
|
Original Post: Fast content-aware image resizing
Feed Title: Eigenclass
Feed URL: http://feeds.feedburner.com/eigenclass
Feed Description: Ruby stuff --- trying to stay away from triviality.
|
Latest Ruby Buzz Posts
Latest Ruby Buzz Posts by Eigen Class
Latest Posts From Eigenclass
|
|
A simple content-aware image resizer, quite small, readable and fast: over 6 times faster than the LiquidRescale GIMP plugin, which is written in C.
Seam carving is a recently presented method to resize images "intelligently",
by removing pixels of the image that carry little information. It can do
things like turning this image
into
this one
Go watch the video for more examples.
I first heard about
content-aware image resizing using seam carving
about one month ago, when I found this
implementation written in Python
that uses SciPy/NumPy, i.e., lots of C code.
I quickly reimplemented it in OCaml, obtaining an unexpected
two-order-of-magnitude speed increase. This was slightly surprising because the Python version uses optimized extensions written in C, and Psyco should have brought the parts written in Python to at least one tenth of the native speed. In this case, the key, it turns out, was not the implementation language but the algorithm itself.
Read more...
Read: Fast content-aware image resizing