repeatability

Typically: "How do I... ", "How can I... " questions
Post Reply
amal.ali
Posts: 5
Joined: 31 Oct 2022, 13:24

repeatability

Post by amal.ali »

hello
I have a problem with the repeatability of my project!!
I am working on swarm robots using the kilobot model you provide with the simulator
now I'm working with 18 robots to test my algorithm, the behavior changes a lot from one run to another, although the code or initial values are not changed, plus, my colleague tried it and we got a different behavior
We are both working on the latest Coppelia edu version, but I am using windows 10 and she is using Ubuntu
i had the same problem when I imported a model that I designed of a mobile robot

coppelia
Site Admin
Posts: 10339
Joined: 14 Dec 2012, 00:25

Re: repeatability

Post by coppelia »

Hello,

you will not be able to get exactly the same results, from one platform to another, because the way the various physics engines are compiled/operate internally. Additionally, depending on the engine, there might be a randomizing function that might help balance constraints/contact points/etc.
Did you try to run with a different physics engine to see if you still get different results from one run to another on the same machine?

Cheers

amal.ali
Posts: 5
Joined: 31 Oct 2022, 13:24

Re: repeatability

Post by amal.ali »

Yes I tried different engines on the same machine with the same variables and the behavior also changes,
Sometimes it gives the expected result, and sometimes it behaves in a very strange way!
I just need to know the concept of repeatability in the simualtor, why it gives these different results, and what result should i take as the right one or the closest one to reality, because I need to validate the result of a research about swarm robots

coppelia
Site Admin
Posts: 10339
Joined: 14 Dec 2012, 00:25

Re: repeatability

Post by coppelia »

In general, a physics engine, even if perfectly repeatable, cannot be trusted as you could trust a geometric algorithm. There are many approximations, simplifications, and of course, since each calculation relies on the previoudly calculated state, errors will very quickly propagate, etc.
If the simulation results vary a little bit, but the overall task is satisfied, then that should be fine. If however, calculation results are greatly different from one run to another then there is probably another problem with your simulation set-up.

Can you post a minimalistic, self-contained scene that illustrates the problem you are mentioning?

Cheers

amal.ali
Posts: 5
Joined: 31 Oct 2022, 13:24

Re: repeatability

Post by amal.ali »

I can provide you with videos of the simulation with the settings I am using in the simulation.
I will send the information as soon as possible.
thankfully

amal.ali
Posts: 5
Joined: 31 Oct 2022, 13:24

Re: repeatability

Post by amal.ali »

Hello again
in the following link, there are multiple videos that show the problems we faced using Coppeliasim and the provided kilobot model.
In vedios record1-Slippage and record2_Slippage: the robots are supposed to be steady, the applied code is the one provided with the kilobot controller which keeps the robot non-moving, and we realize that along the simulation robots start to slip. Also, this problem came out while testing the algorithm multiple times, some robots after they settle in the right places in the shape, they start slipping for no reason! and this behavior is not always observed.
In videos showing Big t-shape, we tried multiple runs of the same scene and the same code, with the same settings (default settings), and the result differs a lot from one run to another, the behavior is not stable nor repeatable.
note that the ubuntu video is speeded up.
https://drive.google.com/drive/folders/ ... share_link

coppelia
Site Admin
Posts: 10339
Joined: 14 Dec 2012, 00:25

Re: repeatability

Post by coppelia »

From the videos it is difficult to see what needs to be seen, and very long recordings.

Did you try to switch to another engine because of the slippage? Please try with the MuJoCo engine.
You can also do following to reduce slippage with some of the other engines: increase the inertia of all shapes by a factor of e.g. 8. And increase the mass of the 3 contact points by a factor of e.g. 4: you will see that the robot will be much more stable.

Without touching the robot, and running the simulation for a while, while recording an animation from the robot ([menu bar --> Modules --> Animation capture]), the robot will slip a bit. But repeating the simulation will generate the exact same movements.
Of course if you have control code for your robot, and you do not perfectly synchronize that control code, then you will obtain different results.

Cheers

amal.ali
Posts: 5
Joined: 31 Oct 2022, 13:24

Re: repeatability

Post by amal.ali »

I apologise for uploading the long recordings, I mixed up the videos.
I have updated the videos with shorter ones showing the differences in the result. Where Run3 on windows and run1 on ubuntu represent the right expected behavior, the rest of them are a total mess!
I will try the solutions you proposed
Thank you for your help and patience

Post Reply