5dafbde8a22a81827514d41513f32ea9be63a9b2,ml/rl/test/gym/open_ai_gym_environment.py,OpenAIGymEnvironment,policy,#OpenAIGymEnvironment#Any#Any#Any#,108
Before Change
action_str = predictor.discrete_action_policy(next_state_dict)[1]
action_idx = self.actions.index(action_str.decode("utf-8"))
else:
action_score_dict = predictor.predict(next_state_dict)[0]
best_action = None
best_score = None
for action_name, action_score in action_score_dict.items():
After Change
if isinstance(predictor, DiscreteActionPredictor):
action_str = predictor.discrete_action_policy(next_state_dict)[1]
action_idx = self.actions.index(action_str.decode("utf-8"))
elif isinstance(predictor, ContinuousActionDQNPredictor):
normed_action_keys = sorted(self.normalization_action.keys())
best_action = None
best_score = None
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 3
Instances
Project Name: facebookresearch/Horizon
Commit Name: 5dafbde8a22a81827514d41513f32ea9be63a9b2
Time: 2018-03-20
Author: edoardoc@fb.com
File Name: ml/rl/test/gym/open_ai_gym_environment.py
Class Name: OpenAIGymEnvironment
Method Name: policy
Project Name: beancount/smart_importer
Commit Name: 220bbe01ba1ac54adba6bc0e301cb22c7d9b90bb
Time: 2018-05-08
Author: patrick@ch.tario.org
File Name: smart_importer/predict_payees.py
Class Name: PredictPayees
Method Name: enhance_transactions
Project Name: studioml/studio
Commit Name: 8ed9daf4707d86f8fe754045ae819b0961bdd290
Time: 2017-07-26
Author: peter.zhokhov@sentient.ai
File Name: studio/model_util.py
Class Name: KerasModelWrapper
Method Name: __call__