Mujoco warning: Linesearch objective is not convex

Discussion in 'Simulation' started by Youngwoon Lee, Jun 16, 2019.

  1. I'm using mujoco-py and I recently got the error ('Linesearch objective is not convex') in sim.step() or sim.forward() methods.

    It seldom happens, like once a 100k steps, so it is difficult for me to spot the problem.

    Can you give some possible reasons for this error?
     
    Samarth Brahmbhatt likes this.
  2. Just a blatant guess: Do you modify values such as mass online. I can imagine that if you do sth. stupid like setting a mass to a negative value ...
     
  3. Thanks for the answer.

    I didn't change a mass, but I set ctrl, qvel, and qacc to zero to make a robot stable after moving to a certain configuration (like every 10 step function calls).
    Can this cause the problem?
     
  4. qacc is the output of the forward dynamics so there is no point in setting it. You can set qvel to zero but I think its implausible to do so. I have no idea whats actuall wrong in your simulation, you approach to stabilizing the robot sounds somewhat hacky. Id try to use some joint damping or maybe just a pd controller.
     
  5. Any news on that one?

    I am also getting it, and I am not sure where and why occurs. I observed that this it started appearing when I set ```condim = 4''' for one of my geoms (while with ```condim= 3''' it never appeared). I have also observed that the warning occurs much more frequently when the torsional friction values are close or larger than the sliding friction values, and that it tends to produce weird artefacts like the object randomly shooting off the surface it is resting on.

    In addition to information on when and why this error might occur, does anyone know if we do anything about it? Like replace linesearch with some other algorithm for example? Or perhaps the linear and torsional frictions need to have a certain relationship between them to be stable?
     
    Last edited: Oct 25, 2019