keras - HDF5Matrix导致"太多打开文件"错误

时间:2017-06-17 21:01:36

标签: python keras hdf5 large-data

HDF5Matrix Keras函数导致OSError: [Errno 24] Too many open files错误。我有~1200 hdf5个用于训练神经网络的文件。我系统中最大打开文件数限制为1024.我使用HDF5Matrix函数的方式是错误的还是函数中的错误。

除了编写自己的hdf5读者之外,我的情况是否有解决办法?

我的阅读文件的代码:

while True:    
    file = .... # choose file to open 
    x1 = HDF5Matrix(file, 'small')
    x2 = HDF5Matrix(file, 'vgg224')
    y = HDF5Matrix(file, 'ab_hist')

    # do something with x1, x2,

0 个答案:

没有答案
相关问题