From the course: Fundamentals of Dynamic Programming
Unlock this course with a free trial
Join today to access over 24,700 courses taught by industry experts.
Project: Using backpointers to reconstruct seams - Python Tutorial
From the course: Fundamentals of Dynamic Programming
Project: Using backpointers to reconstruct seams
- [Narrator] We now know how to find the end of a low energy seam, but our algorithm tells us nothing about the rest of the seam. So let's use back pointers to reconstruct the entire seam. The dynamic programming table you construct it, tells you the optimal values you've computed. In each entry of the table, a back pointer represents what choice you made, to get that optimal value. Let's apply that to the seam finding algorithm. Let's say we have these pixel energies, and we're calculating the seam energies. The first row is just initialized with individual pixel energies. The first pixel in the second row comes out to be 11, and that's based on choosing to continue a seam, from the second pixel of the first row. The next three pixels in the second row, are all based on choosing to continue, the third pixel of the first row. And similarly, we fill out the third row of seam energies. While the seam energy values are…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
What is content-aware image resizing?3m 26s
-
(Locked)
Preprocessing: Defining the energy of an image2m 31s
-
(Locked)
Project: Calculating the energy of an image3m 41s
-
(Locked)
Solution: Calculating the energy of an image2m 20s
-
(Locked)
Using dynamic programming to find low-energy seams3m 31s
-
(Locked)
Project: Finding low-energy seams3m 26s
-
(Locked)
Solution: Finding low-energy seams2m 42s
-
(Locked)
Project: Using backpointers to reconstruct seams3m 50s
-
(Locked)
Solution: Using backpointers to reconstruct seams3m 9s
-
(Locked)
Project: Removing low-energy seams2m 12s
-
(Locked)
Solution: Removing low-energy seams2m 13s
-
-
-