title: How to use OpenCV cornerSubPix() in Python?
body: <p>I'm trying to get and paint corner points in an image. Now, I have a list of tuples with the following format: <code>(row,column,scale)</code> (scale is because I'm using a Gaussian Pyramid), obtained from harrisCornerDetector and nonMaximumSupression process manually. This list is <code>featuresy1</code>.</p>
  
  <p>My code is the following:</p>
  
  <pre><code>r,g,b=cv2.split(image)
  criteria = (cv2.TERM_CRITERIA_EPS + cv2.TERM_CRITERIA_MAX_ITER, 30, 0.001)
  cv2.cornerSubPix( r, featuresy1, (5,5), (-1,1), criteria )
  </code></pre>
  
  <p>Where image is an image in grayscale with three identical shapes. As you can see, I'm giving to <code>cornerSubPix</code> as second parameter a structure like this: <code>[(x1,y1,scale1),(x2,y2,scale2),...,(xn,yn,scalen)]</code>.</p>
  
  <p>This is throwing the following error:</p>
  
  <pre><code>cv2.cornerSubPix( r, featuresy1, (5,5), (-1,1), criteria )
  TypeError: corners is not a numpy array, neither a scalar
  </code></pre>
  
  <p>For this reason I wonder what type, format or structure should have <code>featuresy1</code> to do <code>cornerSubPix()</code> working. Is this the only thing I'm doing wrong? There isn't much documentation about this.</p>
  
  <p>Thanks!</p>