7006c7a182a991b9409c206c56abc121eaffafb5,gym/envs/robotics/hand/manipulate_touch_sensors.py,ManipulateTouchSensorsEnv,_get_obs,#ManipulateTouchSensorsEnv#,75
Before Change
if self.touch_get_obs == "boolean":
for touch_sensor_id, site_id in self._touch_sensor_id_site_id:
value = 1.0 if self.sim.data.sensordata[touch_sensor_id] != 0.0 else 0.0
touch_values.append(value)
elif self.touch_get_obs == "log":
for touch_sensor_id, site_id in self._touch_sensor_id_site_id:
value = self.sim.data.sensordata[touch_sensor_id]
touch_values.append(value)
After Change
object_qvel = self.sim.data.get_joint_qvel("object:joint")
achieved_goal = self._get_achieved_goal().ravel() // this contains the object position + rotation
touch_values = [] // get touch sensor readings. if there is one, set value to 1
if self.touch_get_obs == "sensordata":
touch_values = self.sim.data.sensordata[self._touch_sensor_id]
elif self.touch_get_obs == "boolean":
touch_values = self.sim.data.sensordata[self._touch_sensor_id] > 0.0
elif self.touch_get_obs == "log":
touch_values = np.log(self.sim.data.sensordata[self._touch_sensor_id] + 1.0)
observation = np.concatenate([robot_qpos, robot_qvel, object_qvel, touch_values, achieved_goal])
return {
"observation": observation.copy(),
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 4
Instances Project Name: openai/gym
Commit Name: 7006c7a182a991b9409c206c56abc121eaffafb5
Time: 2019-04-02
Author: andrew.melnik.git@gmail.com
File Name: gym/envs/robotics/hand/manipulate_touch_sensors.py
Class Name: ManipulateTouchSensorsEnv
Method Name: _get_obs
Project Name: facebookresearch/ParlAI
Commit Name: e1017f2286cda84d17063cdeb100089e0454c02d
Time: 2018-04-10
Author: edinan@fb.com
File Name: projects/convai2/baselines/language_model/language_model_ppl.py
Class Name: PerplexityWorld
Method Name: parley
Project Name: facebookresearch/Horizon
Commit Name: 4021cdc2b0280973776365d255b0dd8bff5513e8
Time: 2020-02-26
Author: czxttkl@fb.com
File Name: ml/rl/test/evaluation/test_evaluation_data_page.py
Class Name: FakeSeq2SlateTransformerNet
Method Name: forward