remap_reference#
- de_ebsd.index.crosscorr.remap_reference(reference, detector, f, pattern_center, reference_pattern_center)[source]#
Re-project a whole reference pattern into the deformed configuration.
hrebsd()uses a region-only path internally; this is the full-frame version, for inspecting a remap or for building one by hand.- Parameters:
- reference
(H, W)or(N, H, W), broadcast againstf.- detector
Geometry, for the pixel <-> gnomonic conversion.
- f
(N, 3, 3)deformation gradient in the detector frame.- pattern_center, reference_pattern_center
Test and reference pattern centers,
(3,)or(N, 3).
- Returns:
torch.Tensor(N, H, W), bilinearly resampled; rays falling outside the reference come back as zero.