I am trying to read in a hdf file but no groups show up. I have tried a couple different methods using tables and h5py but neither work in displaying the groups in the file. I checked and the file is 'Hierarchical Data Format (version 5) data' (See Update). The file information is here for a reference.
Example data can be found here
import h5py
import tables as tb
hdffile = "TRMM_LIS_SC.04.1_2010.260.73132"
Using h5py:
f = h5py.File(hdffile,'w')
print(f)
Outputs:
< HDF5 file "TRMM_LIS_SC.04.1_2010.260.73132" (mode r+) >
[]
Using tables:
fi=tb.openFile(hdffile,'r')
print(fi)
Outputs:
TRMM_LIS_SC.04.1_2010.260.73132 (File) ''
Last modif.: 'Wed Aug 10 18:41:44 2016'
Object Tree:
/ (RootGroup) ''
Closing remaining open files:TRMM_LIS_SC.04.1_2010.260.73132...done
UPDATE
h5py.File(hdffile,'w') overwrote the file and emptied it.
Now my question is how to read in a hdf version 4 file into python since h5py and tables both do not work?