InverseDynamicFilter#

class pyCGM2.Model.modelFilters.InverseDynamicFilter(iMod: Model, btkAcq: btkAcquisition, procedure: InverseDynamicProcedure | None = None, gravityVector: array = array([0, 0, -1]), scaleToMeter: float = 0.001, projection: MomentProjection = MomentProjection.Distal, globalFrameOrientation: str = 'XYZ', forwardProgression: bool = True, exportMomentContributions: bool = False, **options)#

Compute joint forces and moments from inverse dynamics.

This filter calculates joint forces and moments based on inverse dynamics analysis of a biomechanical model during a dynamic trial.

Parameters:
  • iMod (Model) – A biomechanical model instance.

  • btkAcq (btk.btkAcquisition) – An acquisition instance of a dynamic trial.

  • procedure (Optional[InverseDynamicProcedure]) – An inverse dynamic procedure, if any. Defaults to None.

  • gravityVector (np.array) – The gravity vector, typically [0, 0, -1]. Defaults to np.array([0, 0, -1]).

  • scaleToMeter (float) – Scale factor to convert measurements to meters. Defaults to 0.001.

  • projection (enums.MomentProjection) – Coordinate system in which joint moments and forces are expressed. Defaults to enums.MomentProjection.Distal.

  • globalFrameOrientation (str) – Global frame orientation. Defaults to “XYZ”.

  • forwardProgression (bool) – Flag indicating if subject moves in the same direction as the global longitudinal axis. Defaults to True.

  • exportMomentContributions (bool) – Flag to export moment contributions. Defaults to False.

  • **options – Additional optional arguments.

Kargs:

viconCGM1compatible(bool): replicate the Vicon Plugin-gait error related to the proximal and distal tibia

__init__(iMod: Model, btkAcq: btkAcquisition, procedure: InverseDynamicProcedure | None = None, gravityVector: array = array([0, 0, -1]), scaleToMeter: float = 0.001, projection: MomentProjection = MomentProjection.Distal, globalFrameOrientation: str = 'XYZ', forwardProgression: bool = True, exportMomentContributions: bool = False, **options)#

Methods

__init__(iMod, btkAcq[, procedure, ...])

compute([pointLabelSuffix])

Execute the inverse dynamics analysis and store the results in the acquisition instance.

compute(pointLabelSuffix: str | None = None)#

Execute the inverse dynamics analysis and store the results in the acquisition instance.

Joint forces and moments are calculated and added to the acquisition data.

Parameters:

pointLabelSuffix (str, optional) – Suffix to be added to the label of the output joint forces and moments data. Defaults to None.