diff --git a/rugnux/RugnuxStills.cpp b/rugnux/RugnuxStills.cpp index bbc9049cb..bb8168e05 100644 --- a/rugnux/RugnuxStills.cpp +++ b/rugnux/RugnuxStills.cpp @@ -340,14 +340,13 @@ void Rugnux::RefineStillsGeometry(int start_image, int end_image, int images_to_ // The four held-out fits and the placement on every frame do not depend on each other, and one fit // keeps only five or six cores busy however many threads it is given (measured on 32): all five run - // side by side, each on a fifth of the threads. The placement is computed whether or not the held-out - // residuals then call for it. + // side by side, each with every thread - on a busy machine that measured faster than a fifth each + // (JF16M: 10.9 s against 14.6 s, 18.9 s one after the other). The placement is computed whether or + // not the held-out residuals then call for it. TimingMark placement_mark(logger, "module placement fits"); - const int fit_threads = std::max(1, config_.nthreads / 5); GeometryRefinerSettings st = gr_settings; st.modules = start; st.refine_modules = true; - st.num_threads = fit_threads; auto placement = std::async(std::launch::async, [&] { return RefineGlobalGeometry(nominal, *cell, placing, st); }); @@ -357,7 +356,6 @@ void Rugnux::RefineStillsGeometry(int start_image, int end_image, int images_to_ GeometryRefinerSettings sf = gr_settings; sf.modules = modules; sf.refine_modules = refine; - sf.num_threads = fit_threads; const auto f = RefineGlobalGeometry(nominal, *cell, half[fit], sf); if (!f.ok) return std::numeric_limits::infinity(); @@ -366,7 +364,6 @@ void Rugnux::RefineStillsGeometry(int start_image, int end_image, int images_to_ GeometryRefinerSettings ev = gr_settings; ev.refine_beam_distance = false; ev.modules = f.modules; - ev.num_threads = fit_threads; const auto e = RefineGlobalGeometry(g, f.cell, half[1 - fit], ev); if (!e.ok) return std::numeric_limits::infinity(); @@ -395,7 +392,6 @@ void Rugnux::RefineStillsGeometry(int start_image, int end_image, int images_to_ // so every spot found and every prediction integrated from here on uses it. The image is // not touched. if (config_.module_diagnostics) { - st.num_threads = gr_settings.num_threads; // its fits run one at a time ModuleDiagnosticsInput diag{nominal, *cell, placing, centres, start, st, rm, experiment_.GetDetectorSetup().GetSensorMaterial(), experiment_.GetDetectorSetup().GetSensorThickness_um()};