← Back to team overview

yade-users team mailing list archive

Re: [Question #197582]: "ForceContainer not thread-synchronized" with utils.unbalancedForce()

 

Question #197582 on Yade changed:
https://answers.launchpad.net/yade/+question/197582

Klaus Thoeni proposed the following answer:
Hi Giulia,

I had a similar problem once and it turned out that the problem just appears 
when you are calling utils.unbalancedForce() from the command line during a 
simulation. Do make sure utils.unbalancedForce() has access to the force 
container you have to stop the simulation and call it. I guess if you calling 
it during the simulation yade might still calculating/updating the forces and 
utils.unbalancedForce() cannot access them.

Otherwise just call utils.unbalancedForce() in your script by using the 
PyRunner engine. This will work.

Cheers,
Klaus

On Fri, 18 May 2012 12:45:41 AM Giulia Macaro wrote:
> New question #197582 on Yade:
> https://answers.launchpad.net/yade/+question/197582
> 
> During the simulation, when I ask for the value of the unbalanced force
> with utils.unbalancedForce(), sometimes I get: "RuntimeError:
> ForceContainer not thread-synchronized; call sync() first!" If I continue
> calling this function, sooner or later the unbalanced is calculated. Why
> does it happen?  Is not fundamental in the simulation, but it's a bit
> annoying, and I can't find a reason for that.
> 
> Thanks
> Giulia

-- 
You received this question notification because you are a member of
yade-users, which is an answer contact for Yade.