MCPcopy Index your code
hub / github.com/OpenDriveLab/TCP / evaluate_values

Method evaluate_values

roach/models/ppo_policy.py:136–140  ·  view source on GitHub ↗
(self, obs_dict: Dict[str, th.Tensor])

Source from the content-addressed store, hash-verified

134 distribution.exploration_loss(exploration_suggests), distribution.distribution
135
136 def evaluate_values(self, obs_dict: Dict[str, th.Tensor]):
137 features = self._get_features(**obs_dict)
138 values = self.value_head(features)
139 distribution, mu, sigma = self._get_action_dist_from_features(features)
140 return values.flatten(), distribution.distribution
141
142 def forward(self, obs_dict: Dict[str, np.ndarray], deterministic: bool = False, clip_action: bool = False, only_feature: bool = False, feature_input: np.ndarray = None):
143 '''

Callers

nothing calls this directly

Calls 3

_get_featuresMethod · 0.95
flattenMethod · 0.80

Tested by

no test coverage detected