I am trying to understand how shall I write a for loop to apply separate sobelx filter for a picture. I understand it is a -1, 0, 1 row vector, then multiple a 1,0,-1 coloumn vector, but i am not sure how shall I put it into the for loops for a 3 channel picture. Thanks!
almost. it’s a composition of a derivative/gradient ([-1, 0, 1] or the reverse) in one direction, and a gaussian lowpass ([1,2,1]) in the other direction.