menpofit.error.root_mean_square_distance_normalised_error(shape, gt_shape, distance_norm_f)[source]

Computes the root mean square error between two shapes normalised by a distance measure between two shapes, i.e.



\[\mathcal{F}(s,s^*) = \sqrt{\frac{1}{N}\sum_{i=1}^N(s_i-s^*_i)^2}\]

where \(s\) and \(s^*\) are the final and ground truth shapes, respectively. \(s_i\) and \(s^*_i\) are the coordinates of the \(i\)’th point of the final and ground truth shapes, and \(N\) is the total number of points. Finally, \(\mathcal{N}(s,s^*)\) is a normalising function based on a distance metric between the two shapes.

  • shape (menpo.shape.PointCloud) – The input shape (e.g. the final shape of a fitting procedure).

  • gt_shape (menpo.shape.PointCloud) – The ground truth shape.

  • distance_norm_f (callable) – The function to be used for computing the normalisation distance metric.


error (float) – The computed root mean square normalised error.