Applying external loads to Inverse Dynamics does not seem to make a difference
- Marcel Koczorowski
- Posts: 6
- Joined: Tue Mar 22, 2022 4:32 am
Applying external loads to Inverse Dynamics does not seem to make a difference
I generated a simplified reaction force for two feet of a full body model.
It looks correct in the visualizer. Here's how my xml is set up. After running ID I use the plotter to compare right knee_angle_r from IDresults with the same joint but running ID without external loads. I get two identical results.
What am I getting wrong?
It looks correct in the visualizer. Here's how my xml is set up. After running ID I use the plotter to compare right knee_angle_r from IDresults with the same joint but running ID without external loads. I get two identical results.
What am I getting wrong?
Tags:
- Marcel Koczorowski
- Posts: 6
- Joined: Tue Mar 22, 2022 4:32 am
Re: Applying external loads to Inverse Dynamics does not seem to make a difference
Here's the mot file with forces. It's rather simple but I figured it would make some kind of difference.
I had to compress it to fit here
I had to compress it to fit here
- Nicos Haralabidis
- Posts: 197
- Joined: Tue Aug 16, 2016 1:46 am
Re: Applying external loads to Inverse Dynamics does not seem to make a difference
Hey Marcel,
It looks like you are applying the external force to the left limb, and then inspecting the net moment for the right limb (for which there is no external force applied to it) - the inverse dynamics calculations start distally and then move proximally towards the root segment (typically the pelvis), for each branch (limb). Having external forces applied to the left limb only affect that given limb's moments, those external forces do not affect the opposing limb. Applying or not applying the external force to the left limb does not affect the right limb. Hope that helps!
Nicos Haralabidis
It looks like you are applying the external force to the left limb, and then inspecting the net moment for the right limb (for which there is no external force applied to it) - the inverse dynamics calculations start distally and then move proximally towards the root segment (typically the pelvis), for each branch (limb). Having external forces applied to the left limb only affect that given limb's moments, those external forces do not affect the opposing limb. Applying or not applying the external force to the left limb does not affect the right limb. Hope that helps!
Nicos Haralabidis
- Marcel Koczorowski
- Posts: 6
- Joined: Tue Mar 22, 2022 4:32 am
Re: Applying external loads to Inverse Dynamics does not seem to make a difference
Thank you for the reply.
I have two external forces set up, one for each foot. It's true that forces for left foot are zero because I still have issues to resolve with my force pad. However, forces for the right foot, and they should be set up correctly (same as for left food, just different columns), look like this: The highlighted part is xyz for force and then xyz for origin point of the force. It looks correct in the visualizer for the right foot.
Here's a plot of moments for both knees. With and without external forces. I chose 4 values yet I only see two identical lines. I figured something should be different here. I could share all files I'm currently using in my project if that would help with anything.
I have two external forces set up, one for each foot. It's true that forces for left foot are zero because I still have issues to resolve with my force pad. However, forces for the right foot, and they should be set up correctly (same as for left food, just different columns), look like this: The highlighted part is xyz for force and then xyz for origin point of the force. It looks correct in the visualizer for the right foot.
Here's a plot of moments for both knees. With and without external forces. I chose 4 values yet I only see two identical lines. I figured something should be different here. I could share all files I'm currently using in my project if that would help with anything.
- Nicos Haralabidis
- Posts: 197
- Joined: Tue Aug 16, 2016 1:46 am
Re: Applying external loads to Inverse Dynamics does not seem to make a difference
Hey Marcel,
It is probably easier if you share your files please!
Thanks,
Nicos
It is probably easier if you share your files please!
Thanks,
Nicos
- Marcel Koczorowski
- Posts: 6
- Joined: Tue Mar 22, 2022 4:32 am
Re: Applying external loads to Inverse Dynamics does not seem to make a difference
Files were too large to attach so I include a google drive link. Skeleton includes additional markers that need to be disabled when running IK tool but I added the IK result file as well, so it's not necessary.
https://drive.google.com/drive/folders/ ... sp=sharing
I just can't find any difference at all when adding external forces and they should work at least in the part of the exercise where right foot is on the pressure pad.
I'd greatly appreciate any help with this, perhaps I'm completely misunderstanding how the tool works.
https://drive.google.com/drive/folders/ ... sp=sharing
I just can't find any difference at all when adding external forces and they should work at least in the part of the exercise where right foot is on the pressure pad.
I'd greatly appreciate any help with this, perhaps I'm completely misunderstanding how the tool works.
- Nicos Haralabidis
- Posts: 197
- Joined: Tue Aug 16, 2016 1:46 am
Re: Applying external loads to Inverse Dynamics does not seem to make a difference
Hello Marcel,
Thanks for the files.
I visualised the 87 second IK trial together the ground reaction forces file in GUI. Playing the trial through I notice the participant between ~6-12 seconds is standing on the force plate (1_ground_XXX according to the file) with their right leg, and at ~22 seconds the participant steps on the same plate (1_ground_XXX) with their left foot. According to the .mot file you sent me, ground_XXX contains 0's for all columns whilst 1_ground_XXX contains values.
Are you currently trying to perform inverse dynamics on the entire 86 second trial at once? As in the external loads file you assign the ground_XXX to left foot and 1_ground_XXX to the right foot for the entire duration - however, the tool does not know that at ~19 seconds, for example, 1_ground_XXX should instead be applied to the left foot. This may explain the results you are observing. In which case you could perform multiple separate ID analyses, depending on when a particular foot is in contact with the specific force plate.
Hope that helps.
Nicos
Thanks for the files.
I visualised the 87 second IK trial together the ground reaction forces file in GUI. Playing the trial through I notice the participant between ~6-12 seconds is standing on the force plate (1_ground_XXX according to the file) with their right leg, and at ~22 seconds the participant steps on the same plate (1_ground_XXX) with their left foot. According to the .mot file you sent me, ground_XXX contains 0's for all columns whilst 1_ground_XXX contains values.
Are you currently trying to perform inverse dynamics on the entire 86 second trial at once? As in the external loads file you assign the ground_XXX to left foot and 1_ground_XXX to the right foot for the entire duration - however, the tool does not know that at ~19 seconds, for example, 1_ground_XXX should instead be applied to the left foot. This may explain the results you are observing. In which case you could perform multiple separate ID analyses, depending on when a particular foot is in contact with the specific force plate.
Hope that helps.
Nicos
- Marcel Koczorowski
- Posts: 6
- Joined: Tue Mar 22, 2022 4:32 am
Re: Applying external loads to Inverse Dynamics does not seem to make a difference
Hello,
Sorry for the late reply, it took my a while to get back to the subject and fix my scripts for generating forces.
Here's an example I found with both feet starting on the pad and I think there's alway at least one foot touching the pad.
Forces should apply correctly for both feet now. I do try to generate inverse dynamics for the entire trial at once but now when forces are applied from the start it should work properly? Either way I can't visualise any difference in the moments when using the plot tool. ID results both with and without applied forces look identical.
Here are the new files
https://drive.google.com/drive/folders/ ... sp=sharing
Sorry for the late reply, it took my a while to get back to the subject and fix my scripts for generating forces.
Here's an example I found with both feet starting on the pad and I think there's alway at least one foot touching the pad.
Forces should apply correctly for both feet now. I do try to generate inverse dynamics for the entire trial at once but now when forces are applied from the start it should work properly? Either way I can't visualise any difference in the moments when using the plot tool. ID results both with and without applied forces look identical.
Here are the new files
https://drive.google.com/drive/folders/ ... sp=sharing
- Nicos Haralabidis
- Posts: 197
- Joined: Tue Aug 16, 2016 1:46 am
Re: Applying external loads to Inverse Dynamics does not seem to make a difference
Hey Marcel,
The plot on the left contains ID moments from the left and right knees with the external forces applied, the plot on the right is without external forces applied. I haven't modified your external loads file and I am running the tool via the GUI - filtering the IK result at 6 Hz. Do the values you get more closely resemble those on the left or right plot?
Best wishes,
Nicos Haralabidis
The plot on the left contains ID moments from the left and right knees with the external forces applied, the plot on the right is without external forces applied. I haven't modified your external loads file and I am running the tool via the GUI - filtering the IK result at 6 Hz. Do the values you get more closely resemble those on the left or right plot?
Best wishes,
Nicos Haralabidis
- Marcel Koczorowski
- Posts: 6
- Joined: Tue Mar 22, 2022 4:32 am
Re: Applying external loads to Inverse Dynamics does not seem to make a difference
Thank you for the answer Nicos.
Your screenshot made me realize I was plotting the wrong data this entire time.
What confused me was the "IDResults" that appears after ID tools finishes, I was sure it includes, well, ID results. Instead it's just a copy of the "IKResults" with a different name, which I don't quite understand. I usually work in python where I specify the output file name so I didn't have a problem finding it before.
I found the output file now, I get the results I was expecting. Thank you for the help.
Best regards,
Marcel Koczorowski
Your screenshot made me realize I was plotting the wrong data this entire time.
What confused me was the "IDResults" that appears after ID tools finishes, I was sure it includes, well, ID results. Instead it's just a copy of the "IKResults" with a different name, which I don't quite understand. I usually work in python where I specify the output file name so I didn't have a problem finding it before.
I found the output file now, I get the results I was expecting. Thank you for the help.
Best regards,
Marcel Koczorowski