upxo.pxtal.twinned_simple_3d.steps.steps_pre_twin_validation module
Pre-Twin Validation – Part I of the Twinned FCC walkthrough.
Validates the host-allocated base structure’s grain-SIZE distribution against the EBSD twin-merged reference (twins merged into their parent, since the base structure has no twins yet – comparing against still-twinned EBSD grains would be apples-to-oranges), per axis, via 2D cross-sections + a Wasserstein-distance pass threshold.
- upxo.pxtal.twinned_simple_3d.steps.steps_pre_twin_validation.validate_morphological_representativeness(base, rg, parent_info, n_slices=(10, 10, 10), test_axes=('x', 'y', 'z'), p_percentage=(60.0, 60.0, 60.0), wasserstein_threshold=0.5)[source]
Validates base.lgi (the host-allocated structure) against the EBSD twin-merged grain-size reference.
n_slices/p_percentage: (x, y, z) tuples, one value per axis. test_axes: which of x/y/z to actually test (all three by default).
- Returns:
RepresentativenessValidator3D (validator – validator.axis_acceptance,)
validator.overall_accepted, validator.report() are the results;
pass this straight into steps_orientation_assignment’s functions.