matflow.param_classes.orientations.Orientations#
- class matflow.param_classes.orientations.Orientations(data: numpy.ndarray, ori_format: matflow.param_classes.orientations.OrientationFormat | None = None)#
Bases:
ParameterValue
Methods
For custom initialisation via YAML or JSON.
Generate random uniformly distributed unit quaternions.
Attributes
- Parameters:
data (ndarray) –
ori_format (OrientationFormat | None) –
- classmethod from_JSON_like(data, ori_format)#
For custom initialisation via YAML or JSON.
- classmethod from_random(number)#
- ori_format: OrientationFormat | None = None#
- static quat_sample_random(number)#
Generate random uniformly distributed unit quaternions. :param number: How many quaternions to generate. :type number: int
- Returns:
quats
- Return type:
ndarray of shape (number, 4)
References
https://stackoverflow.com/a/44031492/5042280 http://planning.cs.uiuc.edu/node198.html
- to_dict()#