Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TypeError: 'str' object is not callable #5

Open
TKroos18 opened this issue Nov 13, 2023 · 0 comments
Open

TypeError: 'str' object is not callable #5

TKroos18 opened this issue Nov 13, 2023 · 0 comments

Comments

@TKroos18
Copy link

TKroos18 commented Nov 13, 2023

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant