Texture uniform odf#939
Draft
bnmajor wants to merge 1 commit into
Draft
Conversation
Implement a uniform orientation distribution function representing completely random texture. The constant value is 1 MRD (multiples of a random distribution). - UniformODF class with crystal/sample symmetry validation - Evaluation for single, batch, and arbitrary-shape orientations Signed-off-by: Brianna Major <brianna.major@kitware.com>
7c0aecb to
9359677
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Overview
Adds
UniformODF, a constant orientation distribution function representing completely random (isotropic) texture. TheODFevaluates to a constant 1 MRD (multiples of a random distribution) for every orientation - the standard reference density for texture analysis on SO(3).New API (additive only — no existing signatures changed)
hexrd.phase_transition.texture.UniformODF/hexrd.phase_transition.texture.uniform_odf:.eval(orientations: np.ndarray) -> float | np.ndarray- returns a scalar1.0for a single(3, 3)matrix and an array of ones for any input whose shape ends in(3, 3); raisesValueErrorotherwise.Tests added
1 MRDvalue, and MRD convention.(N, 3, 3)and multi-dimensional(2, 2, 3, 3)inputs, and invalid-shape handling.1 MRDacross crystal symmetries.WPPF'sSYMLISTWho might need to know
hexrd.phase_transition.texture, sinceUniformODFestablishes theODFeval()interface contract.hexrd.powder.wppf.texture-UniformODFmirrors (to avoid depending onWPPF)SYMLIST, and a test will fail if the crystal symmetry list there changes.Affected Workflows
No existing workflows change behavior - this is purely additive. New texture/ODF code can now use
UniformODFas a random-texture reference. Nno change to existing public APIs, CLI, or file formats.Documentation Changes
Other notes
UnimodalODFwork.'axial'sample symmetry was dropped. The sample set is restricted to{triclinic, monoclinic, orthorhombic}to matchDeLaValleePoussinKernels supported sample symmetries.'axial'has no current consumer.hexrd.powder.wppf.texture.SYMLISTrather than imported, to keep the new texture package decoupled from WPPF. A regression test guards against drift. If depending onWPPFis acceptable this can be changed to import the labels and the regression test can be dropped.Depends on #926