huangwl18 / VoxPoser

VoxPoser: Composable 3D Value Maps for Robotic Manipulation with Language Models
https://voxposer.github.io/
MIT License
521 stars 73 forks source link

TypeError: 'str' object is not callable #5

Open TKroos18 opened 10 months ago

TKroos18 commented 10 months ago

I tried to run playground.ipynb. And I got these error and I do not know what happened.

OpenAI API call took 6.37s planner" generated code context: "objects = ['bin', 'rubbish', 'tomato1', 'tomato2']" objects = ['bin', 'rubbish', 'tomato1', 'tomato2'] Query: throw away the trash, leaving any other objects alone. execute("grasp the rubbish") execute("back to default pose") execute("move to the bin") execute("open gripper") done

Error executing code: objects = ['bin', 'rubbish', 'tomato1', 'tomato2'] execute("grasp the rubbish") execute("back to default pose") execute("move to the bin") execute("open gripper") done

TypeError Traceback (most recent call last) Cell In[5], line 2 1 instruction = np.random.choice(descriptions) ----> 2 voxposer_ui(instruction)

File ~/Graduation/VoxPoser_Pro/VoxPoser/src/LMP.py:146, in LMP.call(self, query, **kwargs) 144 import pdb ; pdb.set_trace() 145 else: --> 146 exec_safe(to_exec, gvars, lvars) 148 self.exec_hist += f'\n{to_log.strip()}' 150 if self._cfg['maintain_session']:

File ~/Graduation/VoxPoser_Pro/VoxPoser/src/LMP.py:189, in exec_safe(code_str, gvars, lvars) 187 except Exception as e: 188 print(f'Error executing code:\n{code_str}') --> 189 raise e

File ~/Graduation/VoxPoser_Pro/VoxPoser/src/LMP.py:186, in exec_safe(code_str, gvars, lvars) 181 custom_gvars = merge_dicts([ 182 gvars, 183 {'exec': empty_fn, 'eval': empty_fn} 184 ]) 185 try: --> 186 exec(code_str, custom_gvars, lvars) 187 except Exception as e: 188 print(f'Error executing code:\n{code_str}')

File :2

File ~/Graduation/VoxPoser_Pro/VoxPoser/src/interfaces.py:100, in LMP_interface.execute(self, movable_obs_func, affordance_map, avoidance_map, rotation_map, velocity_map, gripper_map) 98 if avoidance_map is None: 99 avoidance_map = self._get_default_voxel_map('obstacle') --> 100 object_centric = (not movable_obs_func()['name'] in EE_ALIAS) 101 execute_info = [] 102 if affordance_map is not None: 103 # execute path in closed-loop

TypeError: 'str' object is not callabl

zhenglianchi commented 4 weeks ago

Is the problem solved now?