Closed janEbert closed 6 years ago
That's right, unfortunately, integration might not be possible with integrator accuracy set to high, I believe there is no workaround. @chrisdembia @carmichaelong is there any way to hack this?
I had temporarily introduced a change to allow setting integrator accuracy from Python/Matlab: https://github.com/opensim-org/opensim-core/commit/d09c42953eed8e1b07e014232eef27a73ca4d403 (this commit shows removing the change).
Thank you @chrisdembia . We actually do have an interface to change accuracy through this https://github.com/kidzik/opensim-core/commit/550c2a15d56a918f5fe712d4050b8b5eba84eaeb and this https://github.com/stanfordnmbl/osim-rl/blob/master/osim/env/osim.py#L227-L233
However, @janEbert is trying to put very high accuracy and it crashes. Is there any rule on how high it can go? or any hack to make it less accurate?
Sherm uses the terms "loose accuracy" and "tight accuracy" to avoid the ambiguity of "low accuracy" and "high accuracy."
That exception message just means the accuracy level is too loose.
Maybe emit a warning, clip the value or do not allow too high/loose values?
Thanks @janEbert. I think the solution is a warning or clearer error message. It is not possible to clip the value because the appropriate clipping value depends on the model and motion.
@janEbert I created an issue in the simbody repository (https://github.com/simbody/simbody/issues/639).
It is not possible to clip the value because the appropriate clipping value depends on the model and motion.
This is an important point, and particularly tricky here since motions are being generated on the fly. That being said, it might be good to have a rough guideline somewhere. It sounds like @janEbert has found a cutoff accuracy that seems to work pretty well at 0.001, which agrees with what I've been using with a similar model.
Ah yes, giving guidelines is a good idea.
Setting a too low integrator accuracy (or - given the parameter - too high) leads to the following exception:
I received the exception using
ProstheticEnv
s instantiated with integrator_accuracy >= 0.01. There were no problems with values <= 0.001.Slightly more detailed information: I trained four walkers using different integrator accuracies: 0.1, 0.01, 0.001 and 0.00005 (default). This was the only parameter I modified and as mentioned above, there was a related occurence of errors.
I am on Windows 10 using the latest OpenSim version (Python 3.6.1) and followed the recommended installation instructions.