title: Get lists of coordinates from OpenCV contours in Python
body: <p>I am looking for a way to retrieve lists of coordinates from contours generated by OpenCV.</p>
  
  <p>For example, if I have an OpenCV contour:</p>
  
  <pre><code>cnt = [[[272 271]] 
         [[271 272]]
         [[270 272]]
         [[269 272]]
         [[268 272]]]
  </code></pre>
  
  <p>How to create list of contours x coordinates:</p>
  
  <pre><code>x = [273, 271, 270, 269, 268]
  </code></pre>