Algorithms and image processing
Seam Carving Algorithm
A Python implementation of content-aware image resizing that removes connected low-energy seams while preserving more visually significant content.
Context
What the work needed to solve.
Traditional resizing treats every region uniformly. Seam carving uses an energy map to identify paths that can be removed with less visual disruption.
My contribution
- Calculated per-pixel energy from image gradients.
- Found connected low-energy seams through dynamic programming.
- Removed seams iteratively to reach the requested dimensions.
- Built a web demonstration for comparing the result.
Engineering decisions
Choices that can be explained.
Make the algorithm visible
The portfolio interaction separates the original image, energy map, selected seam, and resized result so the process can be understood.
Use dynamic programming
The connected seam is selected from cumulative energy rather than choosing unrelated low-energy pixels.
Selected visual
Evidence from the project.
Evidence
What supports this account.
- Public source repositoryThe implementation is available on GitHub.
- Live demonstrationA public web demonstration is available.