AnalysesXmlCgmDrivenModelProcedure#

class pyCGM2.Model.Opensim.interface.procedures.analysisReport.opensimAnalysesInterfaceProcedure.AnalysesXmlCgmDrivenModelProcedure(DATA_PATH: str, scaledOsimName: str, resultsDirectory: str | None, modelVersion: str)#

Specialized procedure for handling analyses in OpenSim using CGM-driven models.

This class extends AnalysesXmlCgmProcedure to work with CGM-driven models, allowing for the specification and analysis of reference poses.

Parameters:
  • DATA_PATH (str) – Path to the data directory.

  • scaledOsimName (str) – Name of the scaled OpenSim model file.

  • resultsDirectory (Optional[str]) – Directory for storing results. If None, defaults to DATA_PATH.

  • modelVersion (str) – The version of the CGM model to be used.

__init__(DATA_PATH: str, scaledOsimName: str, resultsDirectory: str | None, modelVersion: str)#

Methods

__init__(DATA_PATH, scaledOsimName, ...)

finalize()

Finalizes the process, including renaming and cleanup of the setup files.

forceMotFile(motfile)

getXml()

Retrieves the XML associated with the procedure.

prepareTrial_fromBtkAcq(acq, dynamicFile, ...)

Prepares the trial data from a BTK acquisition for analysis.

prepareTrial_fromMotFiles(kinematicMotFile, ...)

Prepares the trial data from MOT files for analysis.

prepareXml()

Prepares the XML configuration for the analysis in OpenSim.

run()

Executes the analysis using the configured XML files.

setFrameRange(begin, end)

Sets the frame range for the analysis.

setModelVersion(modelVersion)

Sets the model version.

setPose(poseLabel[, qi])

Sets the pose for the CGM-driven model analysis.

setResultsDirname(dirname)

Sets the directory name where the results will be stored.

setSetupFiles(analysisToolTemplateFile, ...)

Sets up the file paths for the analysis tool and, optionally, the external load file.

setTimeRange(begin, end)

Sets the time range for the analysis.

finalize()#

Finalizes the process, including renaming and cleanup of the setup files.

prepareXml()#

Prepares the XML configuration for the analysis in OpenSim.

setPose(poseLabel: str, qi: Dict[str, Any] | None = None) None#

Sets the pose for the CGM-driven model analysis.

Parameters:
  • poseLabel (str) – Label for the pose being analyzed.

  • qi (Optional[Dict[str, Any]]) – Dictionary of joint angles to modify in the reference pose.