title: How to deal with depth of image when using SIFT in opencv python?
body: <p>I want to use SIFT in my processing using opencv in python. I have a gray level image of tissue, I have segmented that image into Patches and I want to find key points on each Patch (<code>here Patch1</code>) using SIFT. </p>
  
  <p>here is part of my code for this:</p>
  
  <pre><code>sift = cv2.xfeatures2d.SIFT_create()
  kp,des = sift.detectAndCompute(Patch1,None)
  </code></pre>
  
  <p>However, when running, it give me the error of image depth:</p>
  
  <pre><code>error:(-5) image is empty or has incorrect depth (!=CV_8U) in function detectAndCompute
  </code></pre>
  
  <p>Then when I try to convert the image again to gray scale it gives this error:</p>
  
  <pre><code>error: depth == CV_8U || depth == CV_16U || depth == CV_32F in function cvtColor 
  </code></pre>
  
  <p>The same errors happen when I try to use ORB too.</p>
  
  <p>My original images have <code>.png</code> format. I did lots of processing on the original image to get i.e. <code>Patch1</code>. May it be because I have done some changes during my processing? 
  Do you know what I should do? or what is wrong?</p>