show_match#
- de_ebsd.viz.maps.show_match(experimental, master, detector, orientation, energy_kev=None)[source]#
The indexing sanity check: experimental vs simulated pattern at the fit.
Renders three panels side by side – the experimental pattern, the pattern
de_ebsd.sim.MasterPattern.project()produces at the indexedorientation, and their (contrast-standardized) difference – so a viewer can see at a glance whether the orientation is right. The middle panel is titled with the normalized cross-correlation (_ncc()) between the experimental and simulated patterns: a contrast-invariant number in[-1, 1]that quantifies the match (~1is a good index).- Parameters:
- experimental
The measured detector image
(H, W)(numpy array or torch tensor; a leading length-1 axis is squeezed).- master
The
de_ebsd.sim.MasterPatternused for indexing.- detector
The
de_ebsd.sim.detector.EBSDDetectorgeometry.- orientation
The indexed orientation as a length-1
orix.quaternion.Rotation(e.g. a single element ofSphericalIndexer.index()’s output).- energy_kev
Energy bin to project (default: the master’s highest).
- Returns:
anyplotlib.FigureA 1x3 figure (experimental | simulated | difference).