Skip to content

Add ImageRegistrationMethodDisplacement1/.Test2 baselines (Mattes metric) - #56

Draft
blowekamp wants to merge 1 commit into
SimpleITK:mainfrom
blowekamp:displacement1-mattes-metric-baselines
Draft

Add ImageRegistrationMethodDisplacement1/.Test2 baselines (Mattes metric)#56
blowekamp wants to merge 1 commit into
SimpleITK:mainfrom
blowekamp:displacement1-mattes-metric-baselines

Conversation

@blowekamp

Copy link
Copy Markdown
Member

New primary baselines for SimpleITK's ImageRegistrationMethodDisplacement1 and ImageRegistrationMethodDisplacement1Test2 examples, generated after switching the example's stage-1 metric from JointHistogramMutualInformation to MattesMutualInformation.

Root cause context: JointHistogramMutualInformation's gradient was fixed in ITK (InsightSoftwareConsortium/ITK#6569), causing these examples to diverge from all existing baselines. Rather than chasing a moving target, the example was switched to MattesMutualInformation, which is unaffected by that fix and (verified) produces byte-identical output between the official SimpleITK v3.0.0b1 release and current ITK main, when run single-threaded.

Generated with ITK_GLOBAL_DEFAULT_NUMBER_OF_THREADS=1 for reproducibility: MattesMutualInformationImageToImageMetricv4's threaded derivative reduction (DerivativeBufferManager::ReduceBuffer) accumulates thread-local buffers into a shared array via mutex-protected += at OS-scheduling-dependent times, and floating-point addition is not associative -- so multi-threaded runs of the same build have small (~0.17-0.25 RMS) run-to-run variance that compounds over the ~74-95 iterations Displacement1Test2 takes to converge. Single-threaded execution eliminates this: confirmed deterministic across repeated runs (RMS 0.0) and identical between old (v3.0.0b1) and new (current main ITK) builds (RMS 0.0).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant