Hello,
I would like to study the effect of hip implant on hip joint moments during generic gait from OpenSim. I have subject-specific (based on CT-scans) models of both femurs and pelvis before and after hip replacement surgery. I have height and body weight info about subject.
I would like to ask your advice how I could merge subject-specific femurs and pelvis with generic OpenSim model and how to import these .stl files to OpenSim.
Thank you in advance for help,
Olanthea
Subject-specific hip with generic OpenSim model
- Olesya Klets
- Posts: 4
- Joined: Thu Dec 05, 2019 5:15 am
- Ayman Habib
- Posts: 2252
- Joined: Fri Apr 01, 2005 12:24 pm
Re: Subject-specific hip with generic OpenSim model
Hello,
Replacing the bone mesh file in the model with your custom mesh file is quite straightforward:
- find the name of the bone mesh file as follows:
+ In the GUI select the bone,
+ Use Property Editor to see the file name used e.g. whatever.vtp
+ place your file custombone.stl in the same folder as model (or in Geometry folder underneath it)
+ use text editor to replace whatever.vtp in the model's .osim file with custombone.stl
+ reload the model.
Keep in mind, however, that meshes are used for visualization only, so the more fundamental question is how to change segment definitions (joints, muscle attachments etc.) to be subject specific. Do you have a plan for how to do that?
Best regards,
-Ayman
Replacing the bone mesh file in the model with your custom mesh file is quite straightforward:
- find the name of the bone mesh file as follows:
+ In the GUI select the bone,
+ Use Property Editor to see the file name used e.g. whatever.vtp
+ place your file custombone.stl in the same folder as model (or in Geometry folder underneath it)
+ use text editor to replace whatever.vtp in the model's .osim file with custombone.stl
+ reload the model.
Keep in mind, however, that meshes are used for visualization only, so the more fundamental question is how to change segment definitions (joints, muscle attachments etc.) to be subject specific. Do you have a plan for how to do that?
Best regards,
-Ayman
- Olesya Klets
- Posts: 4
- Joined: Thu Dec 05, 2019 5:15 am
Re: Subject-specific hip with generic OpenSim model
Dear Ayman,
Thank you for helping me.
I've edited gait2392_simbody.osim and inserted to the same folder .stl files (pelvis, two femurs). When opening the modified .osim file, the model is not visualized. I was thinking maybe it is because the patient's bones are in much bigger scale then other bones and I set scaling to 0.1 but it still didn't help.
I've also copied these .stl files to Geometry folder and it didn't help.
Trying to find out where I made a mistake. Could you please help?
I will attach here the model so you could take a look at the code,
Thank you a lot in advance,
Olanthea
Thank you for helping me.
I've edited gait2392_simbody.osim and inserted to the same folder .stl files (pelvis, two femurs). When opening the modified .osim file, the model is not visualized. I was thinking maybe it is because the patient's bones are in much bigger scale then other bones and I set scaling to 0.1 but it still didn't help.
I've also copied these .stl files to Geometry folder and it didn't help.
Trying to find out where I made a mistake. Could you please help?
I will attach here the model so you could take a look at the code,
Thank you a lot in advance,
Olanthea
- Axel Koussou
- Posts: 56
- Joined: Mon Aug 10, 2020 12:07 am
Re: Subject-specific hip with generic OpenSim model
Hi Olesya,
I also would like to modify subject-specifically the bones of my OpenSim model. Since no answer was provided, I take the liberty of reviving this forum.
Have you finally succeed to visualize the modified model ?
Thanks in advance,
Regards
I also would like to modify subject-specifically the bones of my OpenSim model. Since no answer was provided, I take the liberty of reviving this forum.
Have you finally succeed to visualize the modified model ?
Thanks in advance,
Regards