浏览代码

[skip ci]

/release_3_distributed
Anupam Bhatnagar 5 年前
当前提交
26dc42e5
共有 1 个文件被更改,包括 3 次插入3 次删除
  1. 6
      ml-agents/mlagents/trainers/sac/trainer.py

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


"""
Takes a trajectory and processes it, putting it into the replay buffer.
"""
self._maybe_write_summary(self.get_step + int(self.steps_per_update))
self._maybe_save_model(self.get_step + int(self.steps_per_update))
self._increment_step(self.hyperparameters.buffer_size, self.brain_name)
self._maybe_write_summary(self.get_step + len(trajectory.steps))
self._maybe_save_model(self.get_step + len(trajectory.steps))
self._increment_step(len(trajectory.steps), trajectory.behavior_id)
last_step = trajectory.steps[-1]
agent_id = trajectory.agent_id # All the agents should have the same ID

正在加载...
取消
保存