
Smoothing Categories

SMOOTHING MODULE9.1 SMOOTHING PROCESS The smoothing module is used to remove small random digitizing errors or "noise" from the transformed image sequence. In addition, because the motion of each point is determined by a continuous smooth function, the smoothing module is able to compute point velocities and point accelerations for each frame in the image sequence. Smoothing is always performed following transformation and prior to the presentation phase. It is not necessary to understand the technical basis for smoothing in order to run the smoothing module and as such this section may be skipped. Appendix B, Technical Aspects of Transformation and Smoothing, presents the mathematical basis for the smoothing algorithms used by this module for those desiring a more technical discussion of smoothing theory. The digitizing process involves measuring the location of each body joint. As with any type of measurement, there is no correct value, only an estimate to some known level of accuracy. Therefore, each measurement consists of two parts: the actual or true value, plus an error value due to the inability to perform exact measurements. If there is only a single measurement, it is impossible to separate the error value from the true value. However, if repeated measurements are made, statistical theory allows the estimation and removal of the error, provided the error is of a random nature. Digitized joint locations are a type of repeated measurement. For a number of consecutive frames or time intervals, the location of each joint is measured. These measurements consist of the true joint location plus a random digitizing error due to the inability to position the stylus or cursor to the exact joint location. Two obvious questions are "What is Optional Smoothing?", and "How does one determine the best smoothing values for a given joint?". The smoothing module has been designed to allow visual determination of optimal smoothing by viewing smoothed curves on the graphic display. Often, there is very little difference between the raw displacement curves and the smoothed curves since digitizing errors tend to be small. It is necessary to highlight the differences in these curves in order to tell how well a given smoothing value approximates true joint motion. One method would be to greatly enlarge each curve to allow small variations to be easily viewed. The smoothing module allows for this feature, but there is a better may. In addition to the displacement curves, the smoothing module can display velocity and acceleration curves for each component. Since the derivative of a curve is the slope or rate of change of the values for that curve, taking successive derivatives has the effect of emphasizing or highlighting the variations or "noise" in the data. Thus, by viewing the acceleration curves, the extent of random error remaining in the data can more easily be determined. Smoothing values can then be adjusted accordingly. 9.2 SMOOTHING MAIN MENU Select Smoothing from the Main APAS Menu. A list of all sequences on the current directory will be presented for selection. Be sure that the desired sequence has been completely digitized and transformed before attempting to perform the smoothing operation. It is possible to resmooth a sequence at any time, as the original unsmoothed data is always retained along with the current smoothed data values. The items on the Smoothing Main Menu are used to control the smoothing process. 9.2.1 F1PVA3 Key The F1PVA3 key depends upon the set of curves select using the F2Mode key. For mode, PVA3, F1 will toggle between the X, Y, and Z components. For mode, XYZ, F1 toggles through position, velocity, acceleration, and 3rd derivative. The value selected by F1 is displayed in the Display field located in the upper left corner of the center window of the Main Smoothing Menu.
9.2.3 F3Spectral The F3Spectral key may be used to display the Fourier spectrum or the power spectrum. The value selected using F3 is display next to Spectral in the top half of the of the screen. 9.2.4 F4ReDisplay The F4ReDisplay key is selected to redisplay the graphic display. Any changes in the display format as selected using the F1, F2, and/or F3 keys will be shown. 9.3 TONEXT The smoothing module smooths the coordinate locations for a single point or body joint at a time. ToNext is used to select the next sequential body joint (in the order originally defined) for smoothing. ToNext is selected to start the smoothing process on the first joint. As smoothing on each joint is completed, the smoothed values for the current joint will be saved and the data values for the next joint will be read and smoothed with the default smoothing values. The smoothed curves will appear on the graphic display and the Main Smoothing Menu will remain on the screen for the next function. If the current joint is the last joint in the file, the program exit screen will be displayed with the message that there are no more joints in this sequence. This is the basic cycle or operation mode of the smoothing module. 9.4 XYZ_VALUES As each joint is selected for smoothing, three data curves will appear on the graphic display and information about that joint will appear on the monochrome screen. The data curves on the color monitor show the smoothed and raw values for each of the coordinate components, X, Y, and Z all frames in this sequence. The smoothing module automatically select cubic spline smoothing as well as an initial closeness of fit value for each X, Y, Z coordinate. These values are the default smoothing values and are used each time a new joint is selected in the Advance function. The degree of smoothing for each coordinate of each body joint is controlled by the smoothing value. The smoothing values are shown in the table in the upper portion of the Smoothing Main Menu with columns Z, Y, and Z and rows Next, Current, Last. The smoothing values used for the smoothed curves shown on the graphic display appear in the Current row. The default value is 1.0SP, where SP is the SPline algorithm. The smoothing value for the spline algorithm is the average error allowance for each point on the curve in user units. Thus if the units for this sequence are centimeters the default smoothing value allows the smoothed curves to vary from the raw curves by an average of one centimeter for each point along the curves (i.e., for each frame in the sequence). To change the degree of smoothing for one or more of the coordinate curves, new smoothing values must be entered. Smaller values allow less error and thus fit more closely. Larger values allow more error and thus produce smoother curves. New values are entered by selecting the XYZvalues form the Smoothing Main Menu. The Smoothing Values Screen will ask for the new values to be inserted in the X, Y and Z fields. New smoothing values may be entered for one or more of the coordinate curves by typing a value under the coordinate name and pressing ENTER. To leave the current value unchanged just press ENTER. When all changes have been entered F10Done is pressed to return to the Smoothing Main Menu.. New curves will be drawn on the color monitor to show the results of smoothing with the new values. At the same time the Next row values are copied to the Current row and the previous Current values now appear in the Last row. Since smoothing is a repetitive process, the smoothing value table keeps track of the changing values as optimal smoothing values are determined. 9.5 SMOOTH Smooth is selected when the current joint curves are to be resmoothed using the smoothing values that appear in the Next row in the upper portion of the screen. The Next values are set using the XYZ_values option. When the Smooth function is performed the Current values become the Last values and the Next values become the Current values. After a short pause for computation the new smoothed curves will appear on the graphic display monitor. 9.6 DISPLAY The Display Option Menu is selected when one of the number of display oriented options is to be performed. 9.6.1 Last This option is a toggle switch that allows the display of the last curves to be turned on or off. The Last curves setting is shown in the right hand side of the screen. The default mode is for last curves to be displayed along with the curves for the current smoothing value. Last curves can be compared to the current curves to help determine optimum smoothing. Sometime, when smoothing with values appreciably larger than previous values, the scale of the last curves will be so large that the current curves appear flat along the horizontal axis. By turning off the display of the last curves, the current curves can be observed drawn to full scale. Once better smoothing values have been chosen, the last curves can be turned back on for final comparison. When this option is selected an additional menu will be displayed with Yes for setting the option and No for clearing the option. 9.6.2 X_Y_Z The XYZ is used to select various combinations of the X, Y, and Z coordinate curves for display. Each of these curves may be viewed individually using the entire display, thus giving maximum viewing resolutions. Any two of the three curves may be displayed at the same time for medium viewing resolution. The final choice is to view all three curves at the standard viewing resolution. This is the default mode for the smoothing module. This option is most often used when the current curve is very close to the raw curve or the last curve and an examination of these curves in greater detail is desired by increasing the vertical resolution this option may also be used when smoothing twodimensional sequence, as the Z coordinate is not used and may be removed from the display. Selection of this option displays an additional menu that lists all valid combinations of coordinate curves (single curves, two at a time or all three). When a combination is selected the display will be updated to show this new combination. 9.6.3 TimeExpand The Time_expand is selected to expand a horizontal segment of the data curves to the full horizontal width of the display. Thus, this option increases horizontal viewing resolution when examining portions of the data curves in more detail. Suitable combinations of Timeexpand and X_Y_Z can present data curves enlarged both horizontally and vertically for maximum resolution of detail. When this option is selected an additional menu will be displayed to allow for Set of a new horizontal interval or to Reset the original display. 9.6.4 Color This option allows the colors used for the curves to be changed. The color screen lists the various items that may be changed. When color selection is changed, the new colors are saved and will be used the next time the smoothing module is run. When this option is selected an additional menu will appear showing the various display items for which the color may be set. Once an item is selected a third menu will appear displaying sixteen available colors. The display will then be redrawn using the new color. 9.7 &bnsp;NEW_SEQ The New_seq option is selected once the current sequence has been smoothed and another sequence is to be smoothed. When this option is selected a confirmation screen will appear. If No is selected the current sequence will be kept and the screen will return to the Smoothing Main Menu. If Yes is selected the current sequence will be saved and the Smoothing Main Menu will appear. 9.8 ALGORITHM Algorithm is selected when the algorithm or computational method used to smooth the data is to be changed. When this option is selected the Algorithm Menu will be displayed listing the five smoothing algorithms that may be selected. The current algorithm is displayed in the upper right hand side of the screen. After selected the desired algorithm, Quit is used to return to the Main Smoothing Menu. 9.8.1 Cubic Cubic selects the cubic spline smoothing algorithm. This algorithm is based on traditional spline function theory, but has been enhanced to allow approximate fitting rather than the traditional exact fitting to the data points. The cubic and quintic splines are the most sophisticated of the smoothing algorithms and give the best results in approximating complete data curves. 9.8.2 Digital_filter This algorithm smooths the data points by removing or attenuating "noise" above the selected cutoff frequency while retaining the lower frequency data. The default value for digital filter is 10 Hz. Larger values produce a closer fit while smaller values produce smoother curves. This is just the opposite of spline smoothing. 9.8.3 Polynomial Smoothing with this algorithm is accomplished by approximating the displacement curve with a polynomial of a userselected order using a "least squares" fit. A third order polynomial is the lowest that can be selected if acceleration values are to be computed. Fourth or fifth order polynomials give better results. The default is fourth order polynomial. Higher degree polynomials tend to fit more closely, however there is a significant difference in endpoint behavior between odd and even order polynomial curves so increasing the order by one does not always produce a better fit. 9.8.4 Quintic This algorithm is based on traditional spline function theory, but has been enhanced to allow "approximate" fitting rather than the traditional exact fitting to the data points. The cubic and quintic splines are the most sophisticated of the smoothing algorithms and five the best results in approximating complete data curves. 9.8.5 Fourier 9.9 OPTIONS The smoothing module contains many options designed to enhance the smoothing process. The Options Menu is accessed from the Main Smoothing Menu. 9.9.1 Automatic This mode smooths all the remaining joints in this sequence with the current default smoothing value. It is the equivalent of selecting the Advance function once for each joint after the current one. Automatic smoothing is used when completing the smoothing process, as rapidly as possible and without additional human interaction, is the concern and not obtaining optimal smoothing for each joint. The curves for each joint will still be displayed as smoothing is performed, however, resmoothing of joints is not allowed during the automatic sequence. At the end of this process individual joints may be resmoothed if desired. Typically, the first joint is smoothed and the default smoothing values are then adjusted accordingly and then the Automatic sequence may be selected. Alternately, smoothing with error values may be selected prior to performing the Automatic sequence, which often yields excellent results without additional smoothing. In general, the best smoothing is performed manually rather than in automatic mode. 9.9.2 Impact/Relax This selection is used to change the closeness of fit in selected regions of the data curve, rather than over the entire curve. This option is only used with the cubic spline smoothing method. By applying this option, regions of one or more Impact or Relax points may be specified along the data curves.
The system will ask for the specific point to be moved and then the location where the point is to be moved. Only vertical motion of the cursor is considered, as data points may not be moved along the horizontal (time) axis. The raw data curve will be corrected by moving that point to its new location and the display will be redrawn. 9.9.3.2 Blockmove Blockmove is selected when a block or interval of data points are to be moved on one of the raw data curves. This feature is most often used when, in the process of digitizing, a point becomes obscured for a number of consecutive frames and must be estimated. The result sometimes produces a shifted interval of points along one or more of the data curves and these points can be moved back to a close approximation of their correct value using the block move command. The system will ask for the end points of the block or interval to be moved, to be selected with the cursor, and then the location where the point is to be moved. Only vertical motion of the cursor is considered, as data points may not be moved along the horizontal (time) axis. The raw data curve will be corrected by moving that point to its new location and the display will be redrawn. 9.9.3.4 Interpolate Interpolate is selected when an interval or block of points on a raw data curve is to be replaced with values determined by linear interpolation between the endpoints of the interval. This function is used when a section of one or more of the data curves contains erroneous values, either from digitizing errors or from missing points during digitizing. Interpolation provides a method of approximating the data values for the interval in question. This method of correction is quite effective as long as the interval is relatively small and there are not large fluctuations in the data values for that interval. It is a good idea to use the Relaxed mode (Section 9.9.2) over interpolated intervals to allow the smoothing algorithm more flexibility in fitting a smoothed curve through these data points. When this option is selected, the system will ask for the endpoints of the interval to be replaced. The interval should be large enough so that the endpoints are good data points, but if this is not possible the interval should be kept as small as possible. Once the endpoints have been entered, the data values will be replaced by the interpolated values and the display will be redrawn. 9.9.4 Joint The Joint option is used to smooth a joint out of the normal consecutive sequence of joints accessed using the Advance function. For example, joint could be used to return to a previously smoothed joint to check smoothing or to resmooth that data and ten to proceed to the next joint to be smoothed. Another application might be to smooth a specific joint or joints while skipping other joints. This would be the case if one wished to perform a partial analysis; perhaps only considering the motion of certain body joints or segments and ignoring others. In most cases, it is recommended that all body joints be smoothed. Otherwise certain joint and segment velocities and accelerations would be missing when subsequent analysis functions such as viewing, graphing, and printing were performed. 9.9.5 Default The Default Menu is used to set or change the default smoothing values, which are the values used to perform initial smoothing on each joint. The better the choice of initial smoothing values the less resmoothing is needed to complete the smoothing process.
When Errorvalues is selected the values on the line next to the Sigma field, in the upper portion of the screen, will be updated to show the current error factors for each data coordinate that will be applied to the current smoothing values. When the Errorvalues option is off, the Sigma field displays an "N.A." or not applicable. If the digitized views for this sequence do not contain redigitizing information, the Sigma field will be set to 1.0, which is the identity error factor. Subsequent smoothing values will be modified by the error values computed from redigitized data. The resulting smoothing values (the product of the current value and the sigma factor for each joint) are the ones that will be saved with the smoothed sequence and shown when the smoothing values are reviewed or displayed for each joint on the screen.
9.10 TYPICAL SMOOTHING PROCESS Set the display to Acceleration curve and return to the Smoothing Main Menu. With each curve type other than Position, it will be observed that there is no raw curve, but rather a last curve. This is because the only measured or raw data values are joint displacements. The other curve types are all computed from the smoothed displacement curves. By comparing the current curves to the last curves, the effect of changes in the smoothing values can be observed and used to hone in on the best values to use. This is the recommended procedure for obtaining optimal smoothing values for each joint. While viewing the acceleration curves, try selecting a very low smoothing value for each of the coordinate curves, like a value of 0.3. This causes the smoothed displacement curves to fit very closely to the raw displacement curves; so closely that they actually fit as well as data. The effect on the acceleration curves show large and almost random fluctuations; an impossibility for human motion. Now try smoothing again with an intermediate smoothing value, such as 1.0, for each curve. The acceleration curves become quite smooth; a reasonable approximation of true human motion. Now if a large value such as 5.0 is used for each curve the acceleration curves are virtually flat. True variations in the data have been removed along with the noise. This exercise illustrates the goal of proper smoothing to remove random fluctuations from the acceleration curves while leaving as much of the true variation as possible. The smoothing process may start with higher smoothing values and work down, or with lower smoothing values and work up, until the acceleration curves show maximum smooth variation without random variation.
9.11 SMOOTHING QUICK REFERENCE For most sequences the system's default algorithm, cubic spline, will be adequate. However if the user desires a different smoothing algorithm; Digital Filter, Quintic Spline, Polynomial or Fourier is available. The following example is for cubic spline.

