ºÝºÝߣ

ºÝºÝߣShare a Scribd company logo
SEAM CARVING
@marcelo.cenerino
Broadway Tower (UK)
Scaling
Cropping
Seam Carving
Seam Carving
? Content-aware image resizing technique created in 2007
? Also known as ¡°liquid rescaling¡±
? Available in graphic applications (Adobe Photoshop, GIMP, ¡­)
? Image is reduced in size by one pixel of height (or width) at a time
? The most interesting features of the image are preserved
Image Enlarging
Object Removal
Seams
Energy Function
Dual-Gradient Energy Function
where
analogously for
Energy Function
Computing Seams ¨C Dijkstra¡¯s Shortest Path Algorithm
2 1 5
7 2 9
3 8 0
6 11 3
Computing Seams ¨C Dynamic Programming
Demo
Not a silver bullet
Thank you
github.com/marcelocenerine/seam-carving
Algorithms, Part II on Coursera (starting this month)
Paper: http://www.merl.com/publications/docs/TR2007-087.pdf

More Related Content

Seam carving

Editor's Notes

  • #4: Standard image scaling is not sufficient since it is oblivious to the image content and typically can be applied only uniformly
  • #5: Cropping is limited since it can only remove pixels from the image periphery
  • #6: More effective resizing can only be achieved by considering the image content and not only geometric constraints. can change the size of an image by gracefully carving-out or inserting pixels in different parts of the image. Seam carving uses an energy function defining the importance of pixels. A seam is a connected path of low energy pixels crossing the image from top to bottom, or from left to right. By successively removing or inserting seams we can reduce, as well as enlarge, the size of an image in both directions
  • #12: Seam carving can support several types of energy functions such as gradient magnitude, entropy, visual saliency, eye-gaze movement, and more. No single energy function performs well across all images but in general they all accommodate a similar range for resizing. They vary in the rate at which they introduce visual artifacts and the parts of the image they affect
  • #13: areas of an image with very little variation in colour have less detail and so are better candidates for removal when resizing.
  • #15: The optimal seam can be found using dynamic programming. The first step is to traverse the image from the second row to the last row and compute the cumulative minimum energy M for all possible connected seams for each entry (i, j):
  • #17: images that are too condensed (left) (in the sense that it does not contain ¡®less important¡¯ areas) or where the content layout prevents seams to bypass important parts (right). In such cases the best strategy would be to use scaling