当我想像 emnsit 一样创建 HDF5ClientData 实例时出现此错误。这是我的代码:
TestNIST = tff.simulation.hdf5_client_data.HDF5ClientData("mynist.hdf5")
我之前在 mynist.hdf5 中添加了一些数据。我不知道为什么会这样。
这是我的错误,例如:
KeyError Traceback (most recent call last)
<ipython-input-169-00a78fdc8682> in <module>()
----> 1 TestNIST = tff.simulation.hdf5_client_data.HDF5ClientData("mynist.hdf5")
1 frames
h5py/_objects.pyx in h5py._objects.with_phil.wrapper()
h5py/_objects.pyx in h5py._objects.with_phil.wrapper()
/usr/local/lib/python3.6/dist-packages/h5py/_hl/group.py in __getitem__(self, name)
262
263 Named HDF5 object (Dataset, Group, Datatype)
--> 264 A hard link is created at "name" which points to the
265 given object.
266
h5py/_objects.pyx in h5py._objects.with_phil.wrapper()
h5py/_objects.pyx in h5py._objects.with_phil.wrapper()
h5py/h5o.pyx in h5py.h5o.open()
KeyError: "Unable to open object (object 'examples' doesn't exist)"