python3 hdf5文件 遍历

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/guotong1988/article/details/82801368
import h5py
import numpy as np

f = h5py.File('train/e1_1.hdf5')
key = ""
for k in f.keys():
    key = k
d = f[key]
print(d)
a = np.ones(d.shape)
d.read_direct(a)
print(a)
f.close()

猜你喜欢

转载自blog.csdn.net/guotong1988/article/details/82801368