Python 用tflearn加载keras模型
我已经在Keras中训练了模型,我需要在Tflearn中生成的代码中加载这些模型Python 用tflearn加载keras模型,python,tensorflow,keras,tflearn,Python,Tensorflow,Keras,Tflearn,我已经在Keras中训练了模型,我需要在Tflearn中生成的代码中加载这些模型 我可以使用以下行保存经过Keras培训的模型: model.save('my_model.hdf5') #keras model.save_weights('my_model.hdf5') #keras 它保存了经过训练的模型的体系结构和权重 或者说: model.save('my_model.hdf5') #keras model.save_weights('my_model.hdf5') #keras
我可以使用以下行保存经过Keras培训的模型:
model.save('my_model.hdf5') #keras
model.save_weights('my_model.hdf5') #keras
它保存了经过训练的模型的体系结构和权重
或者说:
model.save('my_model.hdf5') #keras
model.save_weights('my_model.hdf5') #keras
它只保存训练模型的权重
目的是使用以下行将模型加载到tflearn中:
model.load ('example.tflearn') #tflearn
这一行只加载权重,要求在之前传递架构
我尝试从Keras加载由.save和.save生成的文件,并加载了.load of tflearn,但没有成功。