浏览代码

fix bc tests

/develop/add-fire/ckpt-2
Ruo-Ping Dong 4 年前
当前提交
409a161c
共有 3 个文件被更改,包括 3 次插入9 次删除
  1. 2
      ml-agents/mlagents/trainers/ppo/trainer.py
  2. 2
      ml-agents/mlagents/trainers/sac/trainer.py
  3. 8
      ml-agents/mlagents/trainers/tests/torch/test_bcmodule.py

2
ml-agents/mlagents/trainers/ppo/trainer.py


self.saver.register(self.policy)
self.saver.register(self.optimizer)
self.saver.initialize_or_load(self.policy)
self.saver.initialize_or_load()
# Needed to resume loads properly
self.step = policy.get_current_step()

2
ml-agents/mlagents/trainers/sac/trainer.py


self.saver.register(self.policy)
self.saver.register(self.optimizer)
self.saver.initialize_or_load(self.policy)
self.saver.initialize_or_load()
# Needed to resume loads properly
self.step = policy.get_current_step()

8
ml-agents/mlagents/trainers/tests/torch/test_bcmodule.py


NetworkSettings.MemorySettings() if use_rnn else None
)
policy = TorchPolicy(
0,
mock_behavior_specs,
trainer_config,
"test",
False,
tanhresample,
tanhresample,
0, mock_behavior_specs, trainer_config, tanhresample, tanhresample
)
bc_module = BCModule(
policy,

正在加载...
取消
保存