Skip to content

AST-1301 Limit #threads in GainCalAlgorithm

Maik Nijhuis requested to merge ast-1301-limit-gaincalalgorithm-threads into master

If GainCal itself already uses many threads, do not recursively start that many threads in GainCalAlgorithm, too.

Some explanation: GainCalAlgorithm::doStep is the only GainCalAlgorithm function that has a ParallelFor loop (in GainCalAlgorithm::doStep_unpolarized). GainCal calls this function while it already runs itsNFreqCells job using info().nThreads() threads. Using multithreading in GainCalAlgorithm thus only makes sense if itsNFreqCells is smaller than info().nThreads().

Edited by Maik Nijhuis

Merge request reports

Loading