title: TypeError: Expected Ptr<cv::UMat> for argument 'img'
body: <p>I am trying to implement CLAHE...I have already tried all solutions posted on similar posts, but nothing seems to work. I am using Python 3.7 </p>
  
  <pre><code>import cv2
  
  img=cv2.imread("orimg.jpg")
  
  clahe=cv2.createCLAHE()
  
  g_i=cv2.cvtColor(img,cv2.COLOR_BGR2GRAY)
  
  eh_i=clahe.apply(g_i)
  
  cv2.imwrite('newimg.jpg','eh_i')
  </code></pre>
  
  <p><strong>THIS IS THE ERROR I GET ON RUNNING THE CODE:</strong> <code>TypeError: Expected Ptr&lt;cv::UMat&gt; for argument 'img'</code></p>