...
- Select Tools → Scale Model... from the OpenSim main menu bar.
You need the model you want to be scale to be current. To learn how to make a model current visit Opening, Closing, and Using the Navigator Window.
The Scale Tool is controlled by a window with three tabbed panes. The is Settings Pane is used to specify parameters relating to the subject data, the generic model, and how the model is to be scaled. The Scale Factors Pane is used to specify the scale factors for each segment. The Scale Static Pose Weights Panel pane is used to specify weights on marker positions and joint angles for solving an inverse kinematics problem for the static pose. The inverse kinematics solution for the static pose is used to place the virtual markers on the model so that they coincide with the measured marker locations on the subject.
...
The Settings pane is used to specify parameters related to the subject data, the generic model, and how the model is to be scaled. The panel is organized into four main sections, described below.
Generic Model Data
|
Subject Data Section
|
Controlling Model Scaling
|
...
To use measurement-based scaling, a .trc file that contains suitable marker data must be specified. A static trial (i.e., a trial in which the subject is stationary in some known position) is typically used for this purpose. To specify a file containing marker data, check the box labeled Marker data for measurements. When this is done, you will be able to specify a file in the text box to the right. Click the button to browse for a file. Once the marker data is loaded, information about the trial will be displayed in a box on the far right entitled Marker Data. The information includes the total number of markers in the .trc file (the marker data is arranged in columns of x, y, and z coordinates), number of frames, frame rate, and the time interval over which the data is available. The distances between marker pairs used to compute the scale factors for the segments is based on averaging the marker positions over a time interval. To specify the time interval, enter the starting and final times in the text boxes to the right of the label Average measurements between times. The starting time should always be less than or equal to the final time. If you are computing scale factors based on a dynamic trial (i.e., a trial in which the subject was moving), use a small time interval or specify the same starting and final time to pick out a single frame of data.
Adjusting Model Markers
|
Before the virtual markers on the model can be moved, the model must be put into a position that closely matches the position of the subject. This includes placing the model in the correct location in the laboratory (three translations and three rotations) and also finding an appropriate set of joint angles to match the pose of the subject. To do this, the locations of all the experimental markers are averaged over a specified time interval, and an inverse kinematics problem is solved to find the joint angles that minimize the position error between the model markers and the corresponding average experimental markers. To specify the time interval over which the experimental marker locations are averaged, enter the starting and final times in the text boxes to the right of the label Average markers between times. The starting time should always be less than or equal to the final time. If you are using a dynamic trial (i.e., a trial in which the subject was moving), use a small time interval or specify the same starting and final time to pick out a single frame of data.
...
Anchor | ||||
---|---|---|---|---|
|
|
The controls at the bottom of the pane are used to specify the type of scaling and the scale factors for the selected segment. When a body is selected, such as the pelvis, the settings for that segment become editable. You can select one of two radio buttons to Use measurements or Use manual scales. To the right of each of the radio buttons are three text fields that are used to specify the scale factors that will be applied to the segment along the X, Y, and Z axes of the body. A typical choice for reference frames is X perpendicular to the frontal plane pointing forward, Y perpendicular to the transverse plane pointing up, and Z perpendicular to the sagittal plane pointing to the right. The choice of reference frames depends on how the model was constructed and may vary from model to model.
...
To specify scale factors based on measurement:
|
Using Manual Scale Factors
To specify scale factors manually:
|
For each segment, you may choose to apply one uniform scale factor, or three different scale factors along the X, Y, and Z axes of the segment. The checkboxes labeled Uniform to the right of the three scale-factor fields are used to choose between uniform and non-uniform scaling. When checked, equal signs appear between the three scale-factor fields, and any value specified in one field will be propagated to the other two. When a box is not checked, you can specify the measurement or scale factors for the X, Y, and Z directions independently.
...
Clicking the Edit Measurement Set button of the Scale Factors pane brings up an editor that allows you to inspect and edit the definitions of the measurements that can be used to compute scale factors for body segments. The name of each measurement is displayed in the far left-hand column, and the marker pairs that make up a measurement are listed to the right.
|
Anchor | ||||
---|---|---|---|---|
|
Once a marker and possibly a coordinate file have been specified, the specific behavior of the scaling tool can be described and modified using the Weights pane (Figure below). Each entry in the table represents a task in the least-squares matching for either a marker (top table) or a coordinate (lower table). By left-clicking on a row, you select it, making the entry fields below the tables editable so you can specify weights and values for the selected marker(s) or coordinate(s). This means the coordinate is being actively tracked (e.g. constrained to a specific joint angle). You can select multiple rows to edit by using ctrl + left-mouse-click or shift + left-mouse-click.
|
Command-line Execution
The Scaling Tool can also be run using the command scale -S <setup file name>, for example:
Code Block |
---|
scale -S subject01_Setup_Scale.xml |
...
Video Tutorials
Setting up the scale tool:
Widget Connector
Evaluating your results:
...
Panel | ||||||||
---|---|---|---|---|---|---|---|---|
| ||||||||
Next: Scale Setup File Previous: How Scaling Works Home: Scaling |
...