uniform_SO3_sample#

orix.sampling.uniform_SO3_sample(resolution: int | float, method: str = 'cubochoric', unique: bool = True, **kwargs) Rotation[source]#

Uniform sampling of SO(3) by a number of methods.

Parameters:
resolution

Desired characteristic distance between a rotation and its neighbour in degrees.

method

Sampling method, among "cubochoric" (default), "haar_euler", or "quaternion". See Notes for details on each method.

unique

Whether only unique rotations are returned, default is True.

**kwargs

Keyword arguments passed on to the sampling method.

Returns:
rot

Grid containing appropriate rotations.

Notes

The "cubochoric" algorithm is presented in [Roşca et al., 2014] and [Singh and De Graef, 2016]. It is used in both EMsoft and Dream3D to sample SO(3). The method accepts the parameter semi_edge_steps (N in EMsoft) as an alternative to resolution, which is the number of grid points N along the semi-edge of the cubochoric cube.

The sample from the "haar_euler" algorithm is proportional to \(\cos(\beta) d\alpha \: d\beta \: d\gamma\). See for example: https://math.stackexchange.com/questions/3316481/.

The "quaternion" algorithm has a fairly light footprint on the internet, it’s implemented as described in [LaValle, 2006], the ‘gem’ on which it is based can be found at [Kirk, 1995] and has a reference [Shoemake, 1992].