int32 attribute read as int64 by PyNIO

From: Sourish Basu <S.Basu_at_nyahnyahspammersnyahnyah>
Date: Thu Nov 18 2010 - 05:26:58 MST

Hi all,

     I have an HDF file with a bunch of attributes, which are all
integers. On my work machine (SuSE linux on ppc64), PyNIO tries reading
them as int64, returning wrong values. On my home machine (Ubuntu linux
x86_64 on an intel iMac), the attributes are read as int32, and hence
the values are correct. Does anyone know why in the former case PyNIO
thinks that the attributes are 64-bit integers, or how I could fix it?

==== Work machine ====
[5] fid = Nio.open_file('mmix_1991080100_1991090100_glb600x400.hdf','r')
In [6]: fid.ndiff
Out[6]: array([371085174670462736])
In [7]: fid.ndiff.dtype
Out[7]: dtype('int64')

==== Home machine ====
[6] fid = Nio.open_file('mmix_1991080100_1991090100_glb600x400.hdf','r')
[7]: fid.ndiff
[7]: array([86400000], dtype=int32)

     I can provide the file if someone wants to investigate further.



pyngl-talk mailing list
List instructions, subscriber options, unsubscribe:

Received on Thu Nov 18 05:26:45 2010

This archive was generated by hypermail 2.1.8 : Wed Jan 05 2011 - 09:09:56 MST