Problem with the position of the model
Posted: Sat Oct 13, 2018 5:38 am
Hi all,
I'm a beginner with OpenSim, and recently I'm trying to import model file and visualize it through Python. According to the official document, I wrote some code to import the standard model file 'gait2345_simbody.osim' as follow:
When I ran my code, the visualizer runs fine, but the funny thing is that half part of the model is buried under ground as shown below:
Does anyone know how to adjust the position of the model in the visualizer so that the model can 'stand' on the ground? I'm trying to edit the '.osim' file through notepad++, but nothing works yet. Besides, is there some advice about how to deal with the interaction between the feet of model and the ground?
Thanks,
Zurenarrh
I'm a beginner with OpenSim, and recently I'm trying to import model file and visualize it through Python. According to the official document, I wrote some code to import the standard model file 'gait2345_simbody.osim' as follow:
Code: Select all
import opensim
folderName = 'E:/OpenSim 3.3/Models/Gait2354_Simbody'
modelFileName = folderName + '/gait2354_simbody_test.osim'
myModel = opensim.Model(modelFileName)
myModel.setUseVisualizer(True)
myState = myModel.initSystem()
while 1:
myModel.getVisualizer().show(myState)
Does anyone know how to adjust the position of the model in the visualizer so that the model can 'stand' on the ground? I'm trying to edit the '.osim' file through notepad++, but nothing works yet. Besides, is there some advice about how to deal with the interaction between the feet of model and the ground?
Thanks,
Zurenarrh