Thank you, ping. That was all I needed (my next move should be migrating my os to linux...)
I had WinRAR, but I couldn't command line a .Z file decompression.. It's not an elegant solution, but it worked fine. I had very frustrating moments trying to inflate the HDF.Z files using python zlib library... 2011/8/2 ping <[email protected]> > Hi, > > You could try an os.system call to the 7-Zip executable on Windows. > According to the website (http://www.7-zip.org/), it can decompress .Z > files. > > Hanlie > > On Aug 1, 3:17 pm, jpaulini <[email protected]> wrote: > > Hi all, > > > > I'm working with pyhdf to open TRMM Rainfall HDF files. My final > > pourpose is converting them to a numpy array. > > > > Once I downloaded them fromftp:// > disc2.nascom.nasa.gov/ftp/data/s4pa//TRMM_L3/TRMM_3B42 > > using an automated script. I've to manually decompress the donwloaded > > files using WinRAR. Then, processing de inflated files to get the > > numpy array. So I wonder how can I automate the whole process.... > > > > The downloaded HDF files ar Z compressed, I've been trying to inflate > > them using zlib, but it seems that python zlib implemementation can't > > detect header information. > > > > Here are the questions: > > a- Have you faced the same problem? > > a- Somebody knows a better way to do it? (getting numpy arrays from > > the HDF.Z files) > > b- If I were in a unix machine, I'll call decompress using a system > > call, but I'm in a Windows machine. If you know a compress > > implementation on windows, it also will help a lot. > > > > Environment: > > Python 2.5 > > Windows 7 x64 > > pyhdf (SD) > > numpy > > > > Thanks in advance. >
