The purpose of that code is to calculate the load time position of the for the pelvis based on the marker data. Having a good starting guess for the models is sometimes necessary for the kinematic solver.
You will need to change this if your C3D files doesn’t contain that those markers or if they are called something else. You can just set the initial pelvis positions manually if you want. For example:
Thank you for your reply. It helps me a lot. I found some files in txt format in the Input of MoCapModel. If I import my own C3D file. How can I generate these txt files?
Those text files are the output of running marker tracking. They constitute the joint angles which AnyBody uses when running inverse dynamic analysis. Thus, it is some intermediate files which you can see in the step between “Marker tracking” and “Inverse dynamics”
In the old model (AMMR 1.6 which I believe you are using) the marker tracking and inverse dynamics is split into two separate models which you switch between by changing the define statements:
#ifndef MotionAndParameterOptimizationModel
#define MotionAndParameterOptimizationModel 1
#endif
//Set this to 1 if you want to run the inverse dynamic analysis
#ifndef InverseDynamicModel
#define InverseDynamicModel 0
#endif
If you set the MotionAndParameterOptimizationModel to 1 the model will load in a state where it can run Parameter identification (optimizing marker positions and segment length) and then Marker tracking (which is callled MotionOptimization in the old AMMR 1.6 model). Once you have run that model the txt files should be generated.
Hi melund
Thank you very much for your detailed reply.I am sorry to keep asking questions.Now I can load the model, but the person’s initial position is not correct. No matter how I rotate it, I can’t get the correct position. Can I change the initial position of the model by panning?
The model initial position are in general controlled through the mannequi.any file, but in the mocap models this can be controlled though the trialSpecific.any file, because for the mocap models the mannequin.any file links to the values set in the TrialSpecific.any file.