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

Semantic sensor for receptacle #1786

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

Conversation

jimmytyyang
Copy link
Contributor

Motivation and Context

This introduces a feature that adds semantic sensor for the target receptacle

How Has This Been Tested

Run interactive_play.py Screenshot 2024-02-01 at 11 56 23 AM

Types of changes

  • [Development] A pull request that add new features to the habitat-lab task and environment codebase. Development Pull Requests must be small (less that 500 lines of code change), have unit testing, very extensive documentation and examples. These are typically new tasks, environments, sensors, etc... The review process for these Pull Request is longer because these changes will be maintained by our core team of developers, so make sure your changes are easy to understand!

Checklist

  • My code follows the code style of this project.
  • [] I have updated the documentation if required.
  • I have read the CONTRIBUTING document.
  • I have completed my CLA (see CONTRIBUTING)
  • I have added tests to cover my changes if required.

@facebook-github-bot facebook-github-bot added the CLA Signed Do not delete this pull request or issue due to inactivity. label Feb 1, 2024
Copy link
Contributor

@aclegg3 aclegg3 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe it works, but I have a few questions about the internals.


cls_uuid: str = "arm_receptacle_semantic_sensor"

def __init__(self, sim, config, *args, **kwargs):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add type hints. E.g. to clarify that sim:RearrangeSim

)

def _get_rep_text(self, targ_idx):
# Cache the name of the receptacle
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this looking for the closest of a number of target receptacles?

Comment on lines +698 to +703
if obj is not None:
target_receps_id = (
obj.object_id + self.habitat_config.object_ids_start
)
elif ao is not None:
target_receps_id = ao.visual_scene_nodes[0].semantic_id
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems wrong or arcane, can you explain? For objects it looks like the custom instance id for aos it grabs a pre-configured semantic id. 🤔

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed Do not delete this pull request or issue due to inactivity.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants