How to read multiple .hdf files from a directory?

123 views
Skip to first unread message

Utpal Kanti Mukhopadhyay

unread,
Oct 2, 2020, 1:11:48 AM10/2/20
to tak...@gmail.com, h5...@googlegroups.com
Dear Users of h5py,

I have defined a function that takes a .hdf file from a user-defined path and converts it to xarray Simply, I want the same function to work on multiple .hdf files in a directory and convert those to corresponding xarrays. Code and some sample datasets are attached herewith for your suggestions.

hdf_to_xarray_single_file_at_a time_to_send.py: Code

s_er1.jpg and s_er2.jpg are snippets from code.

MLS-Aura_L2GP-O3_v05-00-c01_2006d185.hdf and MLS-Aura_L2GP-O3_v05-00-c01_2007d009.hdf  data used in code is attached below.

The rest are sample .hdf data files. 

Thanks,
Utpal
hdf_to_xarray_single_file_at_a_time_to_send.py
MLS-Aura_L2GP-O3_v05-00-c01_2007d009.hdf
MLS-Aura_L2GP-O3_v05-00-c01_2006d185.hdf
MLS-Aura_L2GP-O3_v05-00-c01_2005d005.hdf
Reply all
Reply to author
Forward
0 new messages