From 71aea24342b1414f9acb07ebfc1eef6b63716fdc Mon Sep 17 00:00:00 2001 From: Tamas Vami Date: Mon, 8 Apr 2024 15:29:39 -0700 Subject: [PATCH] Move msgs in EcalProcessFilter to logging system --- Biasing/include/Biasing/EcalProcessFilter.h | 4 ++++ Biasing/src/Biasing/EcalProcessFilter.cxx | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/Biasing/include/Biasing/EcalProcessFilter.h b/Biasing/include/Biasing/EcalProcessFilter.h index 1e92a81e6..95fb82baa 100644 --- a/Biasing/include/Biasing/EcalProcessFilter.h +++ b/Biasing/include/Biasing/EcalProcessFilter.h @@ -15,6 +15,7 @@ /* Framework */ /*~~~~~~~~~~~~~~~*/ #include "Framework/Configure/Parameters.h" +#include "Framework/EventProcessor.h" // Forward declaration class G4Step; @@ -62,6 +63,9 @@ class EcalProcessFilter : public simcore::UserAction { /// Process to filter std::string process_{""}; + + /// Enable logging + enableLogging("EcalProcessFilter") }; // EcalProcessFilter } // namespace biasing diff --git a/Biasing/src/Biasing/EcalProcessFilter.cxx b/Biasing/src/Biasing/EcalProcessFilter.cxx index 194eef138..9cdc571b9 100644 --- a/Biasing/src/Biasing/EcalProcessFilter.cxx +++ b/Biasing/src/Biasing/EcalProcessFilter.cxx @@ -166,12 +166,12 @@ void EcalProcessFilter::stepping(const G4Step* step) { return; } - std::cout << "[ EcalProcessFilter ]: " + ldmx_log(debug) << "[ EcalProcessFilter ]: " << G4EventManager::GetEventManager() ->GetConstCurrentEvent() ->GetEventID() << " Brem photon produced " << secondaries->size() - << " particle via " << processName << " process." << std::endl; + << " particle via " << processName << " process."; trackInfo->tagBremCandidate(false); trackInfo->setSaveFlag(true); trackInfo->tagPNGamma();