Integration: the radial background correction carries the corrected background into var_bkg (D14)
The correction moved bkg and I but left the non-signal variance carried to the merge at the ring's level. var_bkg = g (n bkg + n^2 bkg_var): its first term is the Poisson share of the background under the signal disk, which is the corrected background, so it now moves with it (CPU, CUDA; Metal runs the CPU correction). The second term - the noise of the ring estimate - and sigma, which is taken from the counts in the disk, do not depend on the curve and are unchanged. Not touched: the strong flag and the centroid are still taken at the uncorrected pedestal. Only reflections the correction is applied to change; tests: the corrected empty aperture's var_bkg moves by n_inner times the background change (CPU), and GPU var_bkg matches the CPU with a curve. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_015CeEGgpKdfkCTJb3YNMJcu (cherry picked from commit 6d85d594a4199e86d67c779b5301e88e48a3ad49)
This commit is contained in:
1 parent
e866262ed6
commit
6940718cf5
4 files changed
+17
-6
No files matched your search
@@ -530,6 +530,7 @@ TEST_CASE("BraggIntegrationEngineGPU_RadialCurveFromRingsMatchesCPU", "[Integrat
|
||||
INFO("mode " << static_cast<int>(mode) << " reflection " << i);
|
||||
CHECK(out_gpu[i].bkg == Catch::Approx(out_cpu[i].bkg).epsilon(0.001).margin(0.05));
|
||||
CHECK(out_gpu[i].I == Catch::Approx(out_cpu[i].I).epsilon(0.01).margin(2.0));
|
||||
CHECK(out_gpu[i].var_bkg == Catch::Approx(out_cpu[i].var_bkg).epsilon(0.001));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user