Skip to content

Commit

Permalink
don't print nb event per par when no dial is attached
Browse files Browse the repository at this point in the history
  • Loading branch information
nadrino committed Dec 1, 2024
1 parent 06f4c9a commit 716450b
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions src/Propagator/src/Propagator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -208,6 +208,8 @@ void Propagator::printBreakdowns() const {

t << GenericToolbox::TablePrinter::NextLine;

bool hasNoDial{true};

for( auto& parSet : _parManager_.getParameterSetsList() ){
if( not parSet.isEnabled() ){ continue; }
for( auto& par : parSet.getParameterList() ){
Expand All @@ -219,6 +221,8 @@ void Propagator::printBreakdowns() const {
t << par.getFullTitle();
t << GenericToolbox::TablePrinter::NextColumn << nbEventForParameter[ &par ].nbTotal;

if( hasNoDial and nbEventForParameter[ &par ].nbTotal != 0 ){ hasNoDial = false; }

if( _showNbEventPerSampleParameterBreakdown_ ){
for( auto& sample : _sampleSet_.getSampleList() ){
if( not sample.isEnabled() ){ continue; }
Expand All @@ -230,8 +234,13 @@ void Propagator::printBreakdowns() const {
}
}

LogInfo << "Nb of event affected by parameters:" << std::endl;
t.printTable();
if( not hasNoDial ){
LogInfo << "Nb of event affected by parameters:" << std::endl;
t.printTable();
}
else{
LogInfo << "Events aren't parametrised." << std::endl;
}

}

Expand Down

0 comments on commit 716450b

Please sign in to comment.