allenai / allenai/ai2thor

`GetInteractablePoses` does not update based on held object

Open
#1,302 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
C#
Stars
1.8k
Forks
296
PR merge metrics
No merged PRs in 30d

Description

Based on the documentation, `GetInteractablePoses` should return poses of which the target object is visible. However, when I tested the function with different handheld objects, the function does not seem to work as expected.
Repro (AI2-THOR 5.0.0, Python 3.10):
```Python
from ai2thor.controller import Controller
env = Controller()
env.reset(f"FloorPlan201")
reachable = env.step(action="GetReachablePositions").metadata["actionReturn"]
target_id = "Drawer|-00.31|+00.63|+03.37"

poses = env.step(
action="GetInteractablePoses",
objectId=target_id,
positions=reachable,
standings=[True],
).metadata["actionReturn"]

env.step(action="PickupObject", objectId="Pillow|-03.15|+00.68|+03.42", forceAction=True)

poses_holding = env.step(
action="GetInteractablePoses",
objectId=target_id,
positions=reachable,
standings=[True],
).metadata["actionReturn"]

print(len(poses) == len(poses_holding)) # Prints True

"""
Should be False as there are poses where pillow will block the view
A couple poses that makes drawer not visible while try to open
{'x': -2.0, 'y': 0.9026566743850708, 'z': 0.5, 'rotation': 90.0, 'standing': True, 'horizon': 30.0}
{'x': -0.75, 'y': 0.9026566743850708, 'z': 3.75, 'rotation': 90.0, 'standing': True, 'horizon': 60.0}
{'x': -0.75, 'y': 0.9026566743850708, 'z': 3.5, 'rotation': 180.0, 'standing': True, 'horizon': 30.0}
"""

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.