230503ac56636d91d53d728c247c6ea3d096eeb9,tf_agents/environments/tf_py_environment_test.py,TFPYEnvironmentTest,testFirstObservationIsPreservedAfterTwoSteps,#TFPYEnvironmentTest#Any#,269

Before Change


    (_, _, _, observation_t), step_data = tf_env.current_time_step()
    _, step_data = tf_env.step(np.array([1]), step_data)
    _, observation = self.evaluate(
        [tf_env.step(np.array([2]), step_data), observation_t])

    self.assertEqual(np.array([0]), observation)

After Change


    else:
      tf_env = tf_py_environment.TFPyEnvironment(py_env)
    time_step = tf_env.current_time_step()
    with tf.control_dependencies([time_step.step_type]):
      action = tf.constant([1])
    next_time_step = tf_env.step(action)
    with tf.control_dependencies([next_time_step.step_type]):
      action = tf.constant([2])
    _, observation = self.evaluate([tf_env.step(action), time_step.observation])
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 4

Non-data size: 5

Instances


Project Name: tensorflow/agents
Commit Name: 230503ac56636d91d53d728c247c6ea3d096eeb9
Time: 2018-11-30
Author: sguada@google.com
File Name: tf_agents/environments/tf_py_environment_test.py
Class Name: TFPYEnvironmentTest
Method Name: testFirstObservationIsPreservedAfterTwoSteps


Project Name: tensorflow/magenta
Commit Name: c47f40414140f71f49aa26e7378e8103d77afd38
Time: 2018-01-04
Author: adarob@google.com
File Name: magenta/models/music_vae/lstm_models.py
Class Name: BidirectionalLstmEncoder
Method Name: encode


Project Name: tensorflow/agents
Commit Name: 230503ac56636d91d53d728c247c6ea3d096eeb9
Time: 2018-11-30
Author: sguada@google.com
File Name: tf_agents/environments/tf_py_environment_test.py
Class Name: TFPYEnvironmentTest
Method Name: testOneStep


Project Name: onnx/onnx-tensorflow
Commit Name: 4ac4dca40d8a123e90f2cf2d4a81d07d70a0b45d
Time: 2020-01-10
Author: wtsang@us.ibm.com
File Name: onnx_tf/handlers/backend/gather_nd.py
Class Name: GatherND
Method Name: version_11