title: Python IndexError only occurs on osx but not linux
body: <p>I'm parsing an RGB .jpg file and it parses fine in linux, but not in mac osx. Both are version 2.7.9</p>
  
  <p>Here's the code:</p>
  
  <pre><code>import numpy
  import Image
  from StringIO import StringIO
  import urllib
  
  def main():
  
      # process terrain input
      terrain_image = numpy.asarray(Image.open(StringIO(urllib.urlopen("http://i.imgur.com/IIv3E1K.jpg").read())))
  
      # swap around axes and drop two of the three layers (they're all identical)
      terrain_image = numpy.swapaxes(terrain_image, 2, 1)
      terrain_image = numpy.swapaxes(terrain_image, 0, 1)
      terrain_image = terrain_image[0]
  
      print "Terrain Image Parsed!"
  
  if __name__ == "__main__":
      main()
  </code></pre>
  
  <p>In Linux, I get this:</p>
  
  <pre><code>Terrain Image Parsed!
  </code></pre>
  
  <p>In osx:</p>
  
  <pre><code>Traceback (most recent call last):
    File "test.py", line 19, in &lt;module&gt;
      main()
    File "test.py", line 14, in main
      terrain_image = terrain_image[0]
  IndexError: too many indices for array
  </code></pre>
  
  <p>Why is there this discrepancy?</p>