restore model error
Created by: Termset
# save the parameters to ./model.ckpt
self.agent.save('./model.ckpt')
I have saved model successfully! And I want to restore model and render.
algorithm = IMPALA(
model,
sample_batch_steps=config['sample_batch_steps'],
gamma=config['gamma'],
vf_loss_coeff=config['vf_loss_coeff'],
clip_rho_threshold=config['clip_rho_threshold'],
clip_pg_rho_threshold=config['clip_pg_rho_threshold'])
agent = MPEAgent(algorithm, obs_shape, act_dim)
agent.restore('./model.ckpt')
Then the TypeError happend:
agent.restore('./model.ckpt')
File "/home/tianqi/anaconda3/lib/python3.6/site-packages/parl/core/fluid/agent.py", line 221, in restore
filename=filename)
File "/home/tianqi/anaconda3/lib/python3.6/site-packages/paddle/fluid/io.py", line 798, in load_params
filename=filename)
File "/home/tianqi/anaconda3/lib/python3.6/site-packages/paddle/fluid/io.py", line 675, in load_vars
raise TypeError("program's type should be Program")
TypeError: program's type should be Program```