1775e89f262111791fabfd40f80a24f74738fe54,rllib/policy/policy.py,,clip_action,#Any#Any#,388
Before Change
raise ValueError("Expected tuple space for actions {}: {}".format(
action, space))
out = []
for a, s in zip(action, space.spaces):
out.append(clip_action(a, s))
return out
else:
return action
After Change
a = np.clip(a, s.low, s.high)
return a
return tree.map_structure(map_, action, action_space)
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 4
Instances
Project Name: ray-project/ray
Commit Name: 1775e89f262111791fabfd40f80a24f74738fe54
Time: 2020-04-28
Author: sven@anyscale.io
File Name: rllib/policy/policy.py
Class Name:
Method Name: clip_action
Project Name: ray-project/ray
Commit Name: 1775e89f262111791fabfd40f80a24f74738fe54
Time: 2020-04-28
Author: sven@anyscale.io
File Name: rllib/models/tf/tf_action_dist.py
Class Name: MultiActionDistribution
Method Name: logp
Project Name: ray-project/ray
Commit Name: 876a1ba5bd0c5570dae7de7e3334bbe85e561d17
Time: 2020-03-06
Author: sven@anyscale.io
File Name: rllib/utils/torch_ops.py
Class Name:
Method Name: convert_to_non_torch_type