title: Reading binary data in python
body: <p>Firstly, before this question gets marked as duplicate, I'm aware others have asked similar questions but there doesn't seem to be a clear explanation. I'm trying to read in a binary file into an 2D array (documented well here <a href="http://nsidc.org/data/docs/daac/nsidc0051_gsfc_seaice.gd.html" rel="nofollow noreferrer">http://nsidc.org/data/docs/daac/nsidc0051_gsfc_seaice.gd.html</a>). </p>
  
  <p>The header is a 300 byte array.</p>
  
  <p>So far, I have;</p>
  
  <pre><code>import struct
  
  with open("nt_197912_n07_v1.1_n.bin",mode='rb') as file:
      filecontent = file.read()
  
  x = struct.unpack("iiii",filecontent[:300])
  </code></pre>
  
  <p>Throws up an error of string argument length.</p>