https://github.com/danasilver/seam-carving
Seam carving for content-aware image resizing.
https://github.com/danasilver/seam-carving
Last synced: 8 months ago
JSON representation
Seam carving for content-aware image resizing.
- Host: GitHub
- URL: https://github.com/danasilver/seam-carving
- Owner: danasilver
- Created: 2016-05-13T01:55:46.000Z (about 10 years ago)
- Default Branch: master
- Last Pushed: 2016-05-17T03:37:25.000Z (about 10 years ago)
- Last Synced: 2025-04-07T23:11:38.868Z (about 1 year ago)
- Language: Python
- Homepage:
- Size: 6.28 MB
- Stars: 13
- Watchers: 0
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## Seam Carving
Middlebury College CS453 (Computer Vision) Final Project
Dana Silver and Shannon Ovitt
[Final Report](http://www.cs.middlebury.edu/~dsilver/vision/seam-carving/)
### Install OpenCV
On OS X:
```sh
$ brew install opencv
```
* [Linux](http://docs.opencv.org/2.4/doc/tutorials/introduction/linux_install/linux_install.html)
* [Windows](http://docs.opencv.org/2.4/doc/tutorials/introduction/windows_install/windows_install.html)
### Usage
Non-interactive usage:
```sh
$ python seamcarve.py image width height
```
* `image` the image to resize
* `width` the new width for the image, smaller than the image's width
* `height` the new height for the image, smaller than the image's height
Interactive usage:
```sh
$ python seamcarve.py image --interactive
```
Both options will open a new window that will animate the seams being removed.
Press any key when the animation is done to close the window.
See the
[final report](http://www.cs.middlebury.edu/~dsilver/vision/seam-carving/)
for full implementation details and results.
### References
* [Seam Carving for Content-Aware Image Resizing](http://www.faculty.idc.ac.il/arik/SCWeb/imret/imret.pdf) (PDF)
* [Seam Carving for Content-Aware Image Resizing](http://www.faculty.idc.ac.il/arik/SCWeb/imret/) (Project Page)
* [Seam carving, Wikipedia](https://en.wikipedia.org/wiki/Seam_carving)