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

Model gets teleported with all links to origin #3308

Open
srediske opened this issue Mar 22, 2023 · 2 comments
Open

Model gets teleported with all links to origin #3308

srediske opened this issue Mar 22, 2023 · 2 comments
Labels
bug Something isn't working

Comments

@srediske
Copy link

srediske commented Mar 22, 2023

Environment

  • OS Version: Ubuntu 20.04
  • Binary gazebo11_11.11.0

Description

We observed a strange behavior in the simulation: The model is sometimes teleported to the origin with all its links and cannot be used afterwards, so it has to be deleted from the sim. It only occurs with the world solver (ODE WorldStep)

This Video shows the problem:

1.mp4

What stands out here is the long-lasting jumping of the contact points. In this model, a nested model is placed with the <include> tag, which sits loosely without a joint. If the nested model is deactivated, it looks like this:

2.mp4

It's stable just after spawn. But the problem still exists, sooner or later the model will teleport (broken) to origin, at least after interaction with the model. We also tested some models from the official gazebo repo, e.g. the coke can:

3.mp4

And what is going on with the contacts after another model is spawned? The contacts from the coke cans look stable and the terminal doesn't spam any annoying ODE errors (ODE Message 3: LCP internal error, s <= 0 (s=...)), but when i spawn another model they suddenly jump around. Also, note that the coke can had jumping contacts right before it teleported to the origin:

4.mp4

Problems with the same symptom but probably different cause:

  1. Hardware interface as supposed cause
  2. revolute2 joint type as supposed cause: All links teleport to origin if model has a revolute2 joint. #2239
  3. Same behavior seen with the demo joint types model from <joint> <axis> not working correctly in combination with <include> inside <model> (nested model) in sdf >= 1.5 unless old behaviour (sdf <= 1.4) is restored via <use_parent_model_frame> #2401

Steps to reproduce

  1. Start world file:
<?xml version="1.0" ?>
<sdf version="1.7">
  <world name="default">
    <include>
      <uri>model://ground_plane</uri>
    </include>
    <include>
      <uri>model://sun</uri>
    </include>

    <physics name="world_solver" type="ode">
      <ode>
        <solver>
          <type>world</type>
          <sor>1.35</sor>
        </solver>
        <constraints>
          <cfm>0.0005</cfm>
        </constraints>
      </ode>
    </physics>

  </world>
</sdf>
  1. Spawn a simple model with oscillating contacts, e.g. the coke can from the gazebo_models repo
  2. Move/Rotate the model to create more contact changes until it moves to the origin
@srediske srediske added the bug Something isn't working label Mar 22, 2023
@traversaro
Copy link
Collaborator

"Model gets teleported to the origin" is the high level behaviour that correspond to the fact that at some points a NaN emerged in simulation, probably as a result of a numerically unstable simulation. Probably it would be easier to debug if you log the actual model state.

@srediske
Copy link
Author

Thanks for your reply!

Here is a log file with a coke_can: state.log.

I can't find any NaN and it seems to me that the only useful part of this log is /physics/contacts and /pose/info, or did I misunderstand logging the model state?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants