浏览代码

Proper dimensions

/develop/contentropy
Ervin Teng 4 年前
当前提交
7502a383
共有 1 个文件被更改,包括 3 次插入1 次删除
  1. 4
      ml-agents/mlagents/trainers/torch/distributions.py

4
ml-agents/mlagents/trainers/torch/distributions.py


def entropy(self):
return torch.mean(
0.5 * torch.log(2 * math.pi * math.e * self.std + EPSILON), dim=1
0.5 * torch.log(2 * math.pi * math.e * self.std + EPSILON),
dim=1,
keepdim=True,
) # Use equivalent behavior to TF

正在加载...
取消
保存