title: applying sobel filter on image
body: <p>I am trying to use sobel filter on an image of a wall but it doesn't work.</p>
  
  <p>My code is :</p>
  
  <pre><code>im=scipy.misc.imread('IMG_1479bis.JPG')
  im = im.astype('int32')
  dx=ndimage.sobel(im,1)
  dy=ndimage.sobel(im,0)
  mag=np.hypot(dx,dy)
  mag*=255.0/np.max(mag)
  cv2.imshow('sobel.jpg', mag)
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/ygqCd.jpg" alt="enter image description here"></p>
  
  <p>I really don't understand where is my mistake.
  Any help would be appreciated ! Thanks in advance !</p>