title: How to get the key from OrderedDict in python
body: <p>I have a below <code>OrderedDict</code> in python:</p>
  
  <pre><code>OrderedDict([(0, array([308, 186])), (2, array([431, 166]))])
  </code></pre>
  
  <p>Is there any way I can separately get the key and its value something like below:</p>
  
  <pre><code>print(odict[0][0])
  print(odict[0][1])
  print(odict[1][0])
  print(odict[1][1])
  </code></pre>
  
  <p>so that I get below output</p>
  
  <pre><code>0
  array([308, 186])
  2
  array([431, 166])
  </code></pre>
  
  <p>but doing above I only get:</p>
  
  <pre><code>308
  186
  431
  166
  </code></pre>
  
  <p>Is there any way I can extract the keys (0, 1, 2, 3..). Please help. Thanks</p>