In the script argument box of a python nexus operation, you can edit: >>> -side=Left -b=50 -e=100 (Left knee calibration between frames 50 and 100) """ import os import traceback import logging import argparse import matplotlib.pyplot as plt import numpy as np # pyCGM2 settings import pyCGM2 from pyCGM2 import log log.setLoggingLevel(logging.INFO) # vicon nexus import ViconNexus # pyCGM2 libraries from pyCGM2 import enums from pyCGM2.Tools import btkTools from pyCGM2.Utils import files from pyCGM2.Nexus import nexusFilters, nexusUtils, nexusTools from pyCGM2.Model import modelFilters from pyCGM2.Configurator import CgmArgsManager from pyCGM2.Lib.CGM import kneeCalibration
# -*- coding: utf-8 -*- """ Created on Mon Oct 10 12:46:40 2016 @author: Fabien Leboeuf ( Salford Univ, UK) """ import numpy as np import scipy as sp import logging import pyCGM2 from pyCGM2 import log; log.setLoggingLevel(logging.INFO) # pyCGM2 from pyCGM2.Tools import btkTools from pyCGM2.Model.CGM2 import cgm from pyCGM2.Model import modelFilters,modelDecorator, frame import pyCGM2.enums as pyCGM2Enums class CGM11_calibrationTest(): @classmethod def basicCGM1_manualOffsets(cls): MAIN_PATH = pyCGM2.TEST_DATA_PATH + "CGM1\\CGM1-TESTS\\KAD-basic\\" staticFilename = "MRI-US-01, 2008-08-08, 3DGA 02.c3d"
# -*- coding: utf-8 -*- import matplotlib.pyplot as plt import numpy as np import logging import pyCGM2 from pyCGM2 import log; log.setLoggingLevel(logging.DEBUG) import pyCGM2 # btk from pyCGM2 import btk # pyCGM2 from pyCGM2.Tools import btkTools from pyCGM2.Model import modelFilters,modelDecorator from pyCGM2.Model.CGM2 import cgm2 import pyCGM2.enums as pyCGM2Enums from pyCGM2.Model.Opensim import opensimFilters # enableLongitudinalRotation in Static and Motion filter rotate along Z class CGM2_SARA_test(): @classmethod def CGM2_3_SARA_test(cls): MAIN_PATH = pyCGM2.TEST_DATA_PATH + "CGM2\\cgm2.3\\Knee Calibration\\" staticFilename = "Static.c3d" leftKneeFilename = "Left Knee.c3d"
# -*- coding: utf-8 -*- import matplotlib.pyplot as plt import numpy as np import logging import pyCGM2 from pyCGM2 import log log.setLoggingLevel(logging.DEBUG) import pyCGM2 # btk from pyCGM2 import btk # pyCGM2 from pyCGM2.Tools import btkTools from pyCGM2.Model import modelFilters, modelDecorator from pyCGM2.Model.CGM2 import cgm2 from pyCGM2 import enums from pyCGM2.Model.CGM2.coreApps import kneeCalibration from pyCGM2.Utils import files from pyCGM2.Model.Opensim import opensimFilters # enableLongitudinalRotation in Static and Motion filter rotate along Z class CGM2_Knee_test(): @classmethod def CGM2_4_SARA_test(cls): MAIN_PATH = pyCGM2.TEST_DATA_PATH + "CGM2\\cgm2.4\\Knee Calibration\\"
# -*- coding: utf-8 -*- import numpy as np import pdb import logging import json import pyCGM2 from pyCGM2 import log log.setLoggingLevel(logging.WARNING) # pyCGM2 from pyCGM2.Tools import btkTools from pyCGM2.Model.CGM2 import cgm from pyCGM2.Model import modelFilters, modelDecorator, frame import pyCGM2.enums as pyCGM2Enums from collections import OrderedDict from pyCGM2.Utils import files class translatorScenario_tests(): @classmethod def scenario1Test(cls): """ basic test. the pyCGM2 marker is not in the c3d. it points to you own label which is not a pyCGM2 marker ( e.g : LASI points to LeftASI) return: => own markers and pyGM2 markers are both IN the final c3d