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

refactor navmesh_utils SimpleVelocityControlEnv and de-duplicate #1970

Merged
merged 2 commits into from
May 24, 2024

Conversation

aclegg3
Copy link
Contributor

@aclegg3 aclegg3 commented May 21, 2024

Motivation and Context

SimpleVelocityControlEnv and similar utils were duplicated with minor convention differences. This PR unifies the conventions and imports a single implementation in the oracle nav skills.

How Has This Been Tested

CI

Types of changes

  • [Refactoring] Large changes to the code that improve its functionality or performance

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.

…ward. Refactor full stack to de-duplicate implementation.
@facebook-github-bot facebook-github-bot added the CLA Signed Do not delete this pull request or issue due to inactivity. label May 21, 2024
Copy link
Contributor

@jimmytyyang jimmytyyang left a comment

Choose a reason for hiding this comment

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

LGTM

linear_velocity = vel[0]
angular_velocity = vel[1]
# Map velocity actions
self.vel_control.linear_velocity = mn.Vector3(
[0.0, 0.0, -linear_velocity]
[linear_velocity, 0.0, 0.0]
Copy link
Contributor

Choose a reason for hiding this comment

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

hi alex, do you know why we do this at first place?

Copy link
Contributor

Choose a reason for hiding this comment

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

why [0.0, 0.0, -linear_velocity]?

Copy link
Contributor Author

@aclegg3 aclegg3 May 24, 2024

Choose a reason for hiding this comment

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

Originally, this was aligned with Habitat's coordinate system. Typical Agent "forward" direction in local space is -Z.
In this PR I unified the treatment to use the X-forward convention of the articulated_agent

@aclegg3 aclegg3 merged commit 5dfa370 into main May 24, 2024
4 checks passed
@aclegg3 aclegg3 deleted the alex-05_21-refactor_SimpleVelocityControlEnv_x_forward branch May 24, 2024 15:43
dannymcy pushed a commit to dannymcy/habitat-lab that referenced this pull request Jun 26, 2024
…ebookresearch#1970)

* refactor navmesh_utils SimpleVelocityControlEnv to conform with x-forward. Refactor full stack to de-duplicate implementation.
dannymcy pushed a commit to dannymcy/habitat-lab that referenced this pull request Jul 8, 2024
…ebookresearch#1970)

* refactor navmesh_utils SimpleVelocityControlEnv to conform with x-forward. Refactor full stack to de-duplicate implementation.
dannymcy pushed a commit to dannymcy/habitat-lab that referenced this pull request Jul 8, 2024
…ebookresearch#1970)

* refactor navmesh_utils SimpleVelocityControlEnv to conform with x-forward. Refactor full stack to de-duplicate implementation.
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