Custom Model Example

Download

Technical information

Download Custom Model Example

Custom Model Example

These are example scripts to provide an example for how to use the following Modules in Python and Matlab:
NexusTrajectory
NexusSegment
NexusAngle
This code will provide examples on how to:
Load marker data from Nexus 2.10 (or later) into Python 3.9 (or later) and MATLAB
Create modeled markers that will be written to the Nexus model outputs
Create segments and populate them in Nexus as Plug-in Gait Bones
Create Angles that will be populated to the Nexus model outputs
Perform global to local and local to global transformations
To run this code in Python 3.9, the customer must have the following modules installed:
  • numpy
  • viconnexusapi
To use these codes, the static trial provided must be first loaded into Nexus 2.x. The Python or MATLAB static script will be run first. The code will create virtual markers, joint coordinate systems and calculate hip, knee and ankle angles. These angles have not been validated, nor are they intended to be used for anything other than an example on how to generate Euler angles.
The static script will also perform global to local transformations and write them as subject parameters to the VSK.
The walking trial will then be loaded and the dynamic script from Python or MATLAB will then be run on it. The same model outputs, joint coordinate systems and angles will be created.
The script will also take the previously written subject parameters and will be used to recreate the knee and ankle joint centers via a local to global transformation.
This code is purely an example and is not meant for analysis. This code has not been validated.
Written by Nev Pires

GET IN TOUCH

Vicon are here to support you on your Motion Capture journey. We’re happy to provide more information, answer questions and help you find the solution you need. Get in touch with our experts today.