Repository navigation
ENH: Test 1D FFT along every direction axis (closes #19) - #76
Merged
hjmjohnson merged 1 commit intoJun 7, 2026
Conversation
dzenanz
approved these changes
Jun 3, 2026
The 1D complex-to-complex FFT was exercised only along axis 0. Add a direction-sensitive check that forward-transforms a delta-at-origin image along each axis and asserts the result is constant on the line parallel to that axis and zero elsewhere, then round-trips the inverse. Covers directions 0,1 (2D) and 0,1,2 (3D). Closes InsightSoftwareConsortium#19
hjmjohnson
force-pushed
the
enh/issue-19-1d-fft-direction-tests
branch
from
June 3, 2026 20:35
5dc561a to
2dffeb9
Compare
dzenanz
approved these changes
Jun 3, 2026
hjmjohnson
marked this pull request as ready for review
June 7, 2026 17:16
hjmjohnson
merged commit Jun 7, 2026
a519718
into
InsightSoftwareConsortium:main
6 of 56 checks passed
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.
Adds direction-axis coverage to the 1D complex-to-complex FFT test. Previously only axis 0 was exercised; this verifies the transform is applied along each requested direction. Closes #19.
Approach
A forward + inverse round-trip along the same axis is identity regardless of whether
SetDirectionis honored, so it cannot prove direction handling. Instead,runDirectionAxisTest<Precision, Dimension>()uses a direction-sensitive signature:Covers directions 0,1 (2D) and 0,1,2 (3D). Image size 8 (only prime factor 2) keeps VkFFT on its exact path, so a tight tolerance (1e-4) is valid.
Local verification
Built against ITK (Ninja, Release) and ran the affected test:
clang-format applied. The
Doublevariant is gated off on the dev machine (nocl_khr_fp64); fp64-capable CI will exercise both precisions.