Inverse Kinematics Time Range Problem

Provide easy-to-use, extensible software for modeling, simulating, controlling, and analyzing the neuromusculoskeletal system.
POST REPLY
User avatar
Olivia Roud
Posts: 1
Joined: Wed Sep 11, 2019 6:44 am

Inverse Kinematics Time Range Problem

Post by Olivia Roud » Mon Nov 25, 2019 5:55 pm

So I am trying to run inverse kinematics and when I put in any time range (0 to 1.5), (0.0083 to 7.666) etc, it won't register that there is a final time and then fails since the final time (0) is before the start time. Even when I edited it in the text editor and wrote: <time_range> 0.008333 12.333333</time_range>, then loaded it into the IK tool it showed the final time was 0.

Tags:

User avatar
Thomas Uchida
Posts: 1793
Joined: Wed May 16, 2012 11:40 am

Re: Inverse Kinematics Time Range Problem

Post by Thomas Uchida » Mon Nov 25, 2019 6:09 pm

When you select a TRC file in the "Marker data for trial" box, the "Time range" boxes are automatically populated to reflect the entire time range in the file. What values are automatically populated when you load your TRC file?

User avatar
P Wesberg
Posts: 10
Joined: Fri Jan 11, 2019 5:55 am

Re: Inverse Kinematics Time Range Problem

Post by P Wesberg » Tue Mar 23, 2021 5:10 am

Hello,

I got a similar problem running opensim via python wrapping:

Code: Select all

Loaded model --model_name-- from file --path--
Running tool .
InverseKinematicsTool Failed: SimTK Exception thrown at InverseKinematicsTool.cpp:328:
  Internal bug detected: InverseKinematicsTool final time (-0.000000) is before start time (1616498308.775000).
  (Assertion 'final_time >= start_time' failed).
In the TRC file there is the time range from 1616498308.775 to 1616498309.947 with a 30 fps.
Maybe Simbody cant handle the EPOCH time in seconds? But in the opensim GUI it works.

When I open the exactly same model, IK_settings and TRC file in the opensim GUI there is no such problem running the IK tool. So my guess is a different in the opensim or simbody version.

opensim GUI 4.2 -> working

opensim core build with
- opensim 4.1 (commit 20d53d6c1145024d100af15acfd8609ee35a5b6a)
- simbody latest (commit 9daf0d26ea22551a5d10114bffd9b02fa51c53bc)

Would be nice to get some ideas. I could use other time, but than i have to store the timestamp somewhere to use it for later analysis.

kind regard,
Philippe

User avatar
P Wesberg
Posts: 10
Joined: Fri Jan 11, 2019 5:55 am

Re: Inverse Kinematics Time Range Problem

Post by P Wesberg » Tue Mar 23, 2021 7:04 am

I just tried to use the last timestamp to set the end time in the ik tool instance

Code: Select all

ik_tool = osim.InverseKinematicsTool(path_to_ik_settings_xml)
ik_tool.setEndTime(time_final)
Unfortuanetely, when debugging my project with vscode it just aborts without any error after the setEndTime().

POST REPLY