f49e5edde58a0f25042d2de1cae044e34f3fc8e9,ml/rl/test/gym/open_ai_gym_environment.py,OpenAIGymEnvironment,policy,#OpenAIGymEnvironment#Any#Any#Any#,173

Before Change


                action_to_take = list(actions[action_idx].keys())
                action_idx = normed_action_keys.index(action_to_take[0])
            elif isinstance(predictor, DDPGPredictor):
                return self.env.action_space.sample()
        action[action_idx] = 1.0
        return action

    def insert_into_memory(

After Change


                action_idx = normed_action_keys.index(action_to_take[0])
            elif isinstance(predictor, DDPGPredictor):
                actions = predictor.predict(next_state_dict)
                return np.array([actions[0].data.numpy()])
        action[action_idx] = 1.0
        return action

    def insert_into_memory(
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 4

Non-data size: 4

Instances


Project Name: facebookresearch/Horizon
Commit Name: f49e5edde58a0f25042d2de1cae044e34f3fc8e9
Time: 2018-04-04
Author: edoardoc@fb.com
File Name: ml/rl/test/gym/open_ai_gym_environment.py
Class Name: OpenAIGymEnvironment
Method Name: policy


Project Name: facebookresearch/Horizon
Commit Name: 09e72f2042e26725632082d93df70cbc86071d38
Time: 2020-05-13
Author: kittipat@fb.com
File Name: reagent/gym/tests/preprocessors/test_replay_buffer_inserters.py
Class Name: TestBasicReplayBufferInserter
Method Name: test_cartpole


Project Name: BYU-PCCL/holodeck
Commit Name: b52e10c176f57e23a4a9623937d6ca92a1603579
Time: 2018-01-04
Author: joshua.greaves@gmail.com
File Name: example.py
Class Name:
Method Name: sphere_example


Project Name: AIRLab-POLIMI/mushroom
Commit Name: 9b44426b7c6f5386692d7c8e038f5de2f09d13db
Time: 2017-11-08
Author: carloderamo@gmail.com
File Name: mushroom/policy/td_policy.py
Class Name: EpsGreedy
Method Name: draw_action