【问题标题】:The error happens when I get access to the .hdf file using the h5py in google colab当我使用 google colab 中的 h5py 访问 .hdf 文件时发生错误
【发布时间】:2021-02-22 04:08:07
【问题描述】:

大家好,我想用 Google Colab 来训练 TSception 框架。我已经使用显示的代码来访问 Google Drive。它显示我已成功链接 Google Drive,如图所示。 enter image description here 然后我使用h5py.File("/content/drive/My Drive/sub_0.hdf", 'r') 读取 Google Drive 中的文件。但出现错误“OSError: Unable to open file (file signature not found)”。

【问题讨论】:

    标签: file google-drive-api google-colaboratory signature h5py


    【解决方案1】:

    只是因为hdf文件是用HDF4函数生成的,所以用HDF5函数读取时会出错。 HDF4和HDF5函数可以写入后缀相同的文件'.hdf'

    【讨论】:

      猜你喜欢
      • 2018-12-01
      • 1970-01-01
      • 2020-04-08
      • 2018-10-26
      • 2020-03-22
      • 2019-12-16
      • 2019-05-20
      • 2017-08-26
      • 2018-08-18
      相关资源
      最近更新 更多