Hello and welcome back. What type of information and images can we use for image and video segmentation? In particular, I want to discuss a bit about Edges and Regions. Let's just look at one very nice image of a flower. we are going to assume that we want to segment out this flower. We want to separate the flower from the background. There are certain regions like here, where there's a very clear boundary. So we have this cast for example, edges and gradients. Remember, the gradient that we represent in this form. Which is nothing else than the vector of the derivative in the image, derivative of the image in each direction, derivative of the image in the Y direction. we talk about how to implement that a few weeks ago. For example, a derivative in the X direction, we could do with a simple filter of plus one, minus one and minus one. Now, if we take these derivatives and we compute the magnitude of their vector, because there are very clear differences in both sides of the flower in this region. Very clearly, that will help us to separate the flower from the background. And we are going to see very often using the gradient as part of our image segmentation algorithms. On the other hand, we see here. We might also get gradients, but we don't want these gradients to be part of the segmentation. There are differences inside the flower that we don't want them to appear. So, clearly we can use this borders, these edges, or this gradient. We don't want to use the ones inside and that makes our life a bit more difficult. But it also tells us that we are not really looking for a uniform region inside the flower. If we were to put that as a constraint in our segmentation, we will not get very far, because inside the flower things change a lot. We are actually looking for big differences between the flower and the background. And therefore, edges are going to be very important to segment this flower. As we're going to see in the future videos. But let us look at that slightly different image. Look at now at this image. We clearly see a ball here, although they're basically, let me just get the pen, they're basically no edges here. We see the ball but we don't see any edges, but we understand the shape, so here we're not going to be able to use edge information, they're no edges if we were to compute the gradient in this region here. Any pixel here we will try to compute the gradient, that gradient will be zero or very low and won't help us to find a border, to find a object of interest. On the other hand, we could use shape, we could use regions, okay? So we could try to understand that this is kind of a uniformed region, kind of a uniformed region. And actually we can use that fact to basically help us obtain the segmentation. Let's just see the edges of this image to further illustrate that edges won't help in this case. So here, I took the green channel of the color image that we just saw and I computed, in this case I used MATLAB. I computed edges. So we see some spurious edges. Those don't bother us too much, we learned in the past how to get rid of them. For example by pre-filtering the image, removing the noise before. We get nice edges here, but no edges here, this is a tiny edge because there is probably a very weak boundary here, but no edges here. So we will need other types of information in order to be able to segment this ball out of the background. Looks very simple, but edges are not sufficient. What I want to show you in the next videos is how to incorporate multiple sources of information. First, we're going to start in the next video with half transform that's going to help us to integrate shape that we know. If we are looking for a line we can put that into the segmentation or the detection algorithm. If we are looking for circle like here, we can incorporate that into the algorithm and we do that with the half transform. I'll see you in the next video for that, thank you.