visualization module

This module allows visualization in (almost) real-time using the OpenSim 4.3 Python-API.

class cyberglove.visualization.Visualization(vis_model='roll', col=<opensim.simbody.Vec3; proxy of <Swig Object of type 'SimTK::Vec< 3 > *'> >)

The class implementing the visualization with OpenSim.

__init__(vis_model='roll', col=<opensim.simbody.Vec3; proxy of <Swig Object of type 'SimTK::Vec< 3 > *'> >)

Initializes an OpenSim-visualizer-session and maps the sensor-set onto the joints/coordinates of visualized model.

Parameters
  • col (osim.Color, optional) – visualization background-color. Defaults to osim.White.

  • vis_model (str, optional) – The visualization model to use (‘flexion’ or ‘roll’). Defaults to ‘roll`.

Returns

None

update_live_view(dataset)

Updates the view according to the dataset which has to be given as angles in degrees.

Parameters

dataset (numpy.ndarray) – one-dimensional array of 22 angle-values given in degrees

Returns

None