pyCGM_Single.pyCGM.pelvisJointCenter

pyCGM_Single.pyCGM.pelvisJointCenter(frame)

Make the Pelvis Axis.

Takes in a dictionary of x,y,z positions and marker names, as well as an index Calculates the pelvis joint center and axis and returns both.

Markers used: RASI, LASI, RPSI, LPSI Other landmarks used: origin, sacrum

Pelvis X_axis: Computed with a Gram-Schmidt orthogonalization procedure [1] and then normalized. Pelvis Y_axis: LASI-RASI x,y,z positions, then normalized. Pelvis Z_axis: Cross product of x_axis and y_axis.

Parameters
framedict

Dictionaries of marker lists.

Returns
pelvisarray

Returns an array that contains the pelvis origin in a 1x3 array of xyz values, which is then followed by a [1x3, 3x3, 1x3] array composed of the pelvis x, y, z axis components, and the sacrum x,y,z position.

References

1

M. P. Kadaba, H. K. Ramakrishnan, and M. E. Wootten, “Measurement of lower extremity kinematics during level walking,” J. Orthop. Res., vol. 8, no. 3, pp. 383–392, May 1990, doi: 10.1002/jor.1100080310.

Examples

>>> import numpy as np
>>> from .pyCGM import pelvisJointCenter
>>> frame = {'RASI': np.array([ 395.36,  428.09, 1036.82]),
...          'LASI': np.array([ 183.18,  422.78, 1033.07]),
...          'RPSI': np.array([ 341.41,  246.72, 1055.99]),
...          'LPSI': np.array([ 255.79,  241.42, 1057.30]) }
>>> [arr.round(2) for arr in pelvisJointCenter(frame)] 
[array([ 289.27,  425.43, 1034.94]), array([[ 289.25,  426.43, 1034.83],
[ 288.27,  425.41, 1034.93],
[ 289.25,  425.55, 1035.94]]), array([ 298.6 ,  244.07, 1056.64])]
>>> frame = {'RASI': np.array([ 395.36,  428.09, 1036.82]),
...          'LASI': np.array([ 183.18,  422.78, 1033.07]),
...          'SACR': np.array([ 294.60,  242.07, 1049.64]) }
>>> [arr.round(2) for arr in pelvisJointCenter(frame)] 
[array([ 289.27,  425.43, 1034.94]), array([[ 289.25,  426.43, 1034.87],
[ 288.27,  425.41, 1034.93],
[ 289.25,  425.51, 1035.94]]), array([ 294.6 ,  242.07, 1049.64])]