浏览代码

reduce initialization weights

/develop/coma2
Andrew Cohen 4 年前
当前提交
c08fefbc
共有 2 个文件被更改,包括 11 次插入1 次删除
  1. 5
      ml-agents/mlagents/trainers/ppo/trainer.py
  2. 7
      ml-agents/mlagents/trainers/torch/networks.py

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


baseline_estimates=baseline_estimates,
v_estimates=v_estimates,
value_next=value_next[name],
gamma=1,
gamma=self.optimizer.reward_signals[name].gamma,
lambd=1,
)

# gamma=self.optimizer.reward_signals[name].gamma,
# lambd=self.hyperparameters.lambd,
#)
#print(local_rewards)
#print(test_v)
#print(value_next[name])
self._stats_reporter.add_stat(
f"Policy/{self.optimizer.reward_signals[name].name.capitalize()} Sum Rewards",
np.mean(test_v),

7
ml-agents/mlagents/trainers/torch/networks.py


self.linear_encoder = LinearEncoder(
encoder_input_size, network_settings.num_layers, self.h_size
)
self.linear_encoder = LinearEncoder(
encoder_input_size,
network_settings.num_layers,
self.h_size,
kernel_gain=(0.125 / self.h_size) ** 0.5,
)
if self.use_lstm:
self.lstm = LSTM(self.h_size, self.m_size)

正在加载...
取消
保存