From the course: Fundamentals of Dynamic Programming
Unlock this course with a free trial
Join today to access over 22,700 courses taught by industry experts.
Preprocessing: Defining the energy of an image - Python Tutorial
From the course: Fundamentals of Dynamic Programming
Preprocessing: Defining the energy of an image
- [Instructor] The energy at a certain pixel in an image is a numerical value that captures how much the image is changing around that pixel. In this way, we can say areas of an image with high energy values are interesting and areas with low energy values are uninteresting. For example, let's take a pixel and the two surrounding pixels on the left and right. If the color changes significantly between these pixels, then the difference between these pixels is large. In contrast, if the surrounding pixels have a color similar to the middle one, the difference is small. To formally define the energy at a pixel we have to look around that pixel both horizontally and vertically. Let's start with the horizontal direction. We'll assume the pixel colors are represented using red, green and blue components. As is typical in computing, then we take the difference of the red values, square it. The difference of the green values…
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
-
-
-