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

Fixes to the urdf to mjcf conversion #5

Merged
merged 6 commits into from
Dec 12, 2024
Merged

Fixes to the urdf to mjcf conversion #5

merged 6 commits into from
Dec 12, 2024

Conversation

alik-git
Copy link
Contributor

@alik-git alik-git commented Dec 11, 2024

Changes:

  • Add a "base" body to the root. TODO: how to correctly compute the inertial values

  • Correct the DOF caclulation

This should be run with

python urdf2mjcf/convert.py \
              ../sim/sim/resources/gpr/robot_fixed.urdf \
              --output ../sim/sim/resources/gpr/robot_fixed.xml \
              --no-frc-limit \
              --default-position ""0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0""

)

# Add inertial properties to base body
ET.SubElement(
Copy link
Contributor

Choose a reason for hiding this comment

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

remove this - this should be automatically computed

@budzianowski budzianowski self-requested a review December 12, 2024 00:42
@@ -39,79 +39,81 @@
<body name="root" pos="0 0 0.63" quat="1 0 0 0">
<freejoint name="root" />
Copy link
Contributor

Choose a reason for hiding this comment

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

this was created with new code but old urdf right?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

correct. the input was

urdf2mjcf/tests/sample/robot.urdf

@codekansas
Copy link
Member

lgtm

@alik-git alik-git merged commit 706532c into master Dec 12, 2024
1 check passed
@alik-git alik-git deleted the conversion_fixes branch December 12, 2024 01:11
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

Successfully merging this pull request may close these issues.

3 participants