ATLAS Offline Software
Public Member Functions | Private Member Functions | Static Private Member Functions | Private Attributes | List of all members
PFSubtractionTool Class Reference

#include <PFSubtractionTool.h>

Inheritance diagram for PFSubtractionTool:
Collaboration diagram for PFSubtractionTool:

Public Member Functions

 PFSubtractionTool (const std::string &type, const std::string &name, const IInterface *parent)
 
 ~PFSubtractionTool ()
 
StatusCode initialize ()
 
void execute (eflowCaloObjectContainer *theEflowCaloObjectContainer, eflowRecTrackContainer *recTrackContainer, eflowRecClusterContainer *recClusterContainer) const
 
StatusCode finalize ()
 

Private Member Functions

unsigned int matchAndCreateEflowCaloObj (PFData &data) const
 This matches ID tracks and CaloClusters, and then creates eflowCaloObjects. More...
 
void performSubtraction (const unsigned int &startingPoint, PFData &data) const
 
void performSubtraction (eflowCaloObject &thisEflowCaloObject) const
 
bool isEOverPFail (double expectedEnergy, double sigma, double clusterEnergy) const
 
bool canAnnihilate (double expectedEnergy, double sigma, double clusterEnergy) const
 
void printAllClusters (const eflowRecClusterContainer &recClusterContainer) const
 

Static Private Member Functions

static std::string printTrack (const xAOD::TrackParticle *track)
 
static std::string printCluster (const xAOD::CaloCluster *cluster)
 

Private Attributes

ToolHandle< IEFlowCellEOverPToolm_theEOverPTool {this, "eflowCellEOverPTool", "eflowCellEOverPTool", "Energy Flow E/P Values and Shower Parameters Tool"}
 Tool for getting e/p values and hadronic shower cell ordering principle parameters. More...
 
std::unique_ptr< eflowEEtaBinnedParametersm_binnedParameters
 
std::unique_ptr< PFMatch::TrackEtaPhiInFixedLayersProviderm_trkpos
 Track position provider to be used to preselect clusters. More...
 
ToolHandle< PFTrackClusterMatchingToolm_theMatchingTool {this, "PFTrackClusterMatchingTool", "PFTrackClusterMatchingTool/CalObjBldMatchingTool", "The track-cluster matching tool"}
 Default track-cluster matching tool. More...
 
ToolHandle< PFTrackClusterMatchingToolm_theMatchingToolForPull_015 {this, "PFTrackClusterMatchingTool_015", "PFTrackClusterMatchingTool/PFPullMatchingTool_015", "The 0.15 track-cluster matching tool to calculate the pull"}
 
ToolHandle< PFTrackClusterMatchingToolm_theMatchingToolForPull_02 {this, "PFTrackClusterMatchingTool_02", "PFTrackClusterMatchingTool/PFPullMatchingTool_02", "The 0.2 track-cluster matching tool to calculate the pull"}
 
Gaudi::Property< bool > m_recoverSplitShowers {this,"RecoverSplitShowers",false,"Toggle whether we are recovering split showers or not"}
 Toggle whether we are recovering split showers or not. More...
 
Gaudi::Property< int > m_nClusterMatchesToUse {this, "nClusterMatchesToUse", 1, "Number of clusters to match to each track"}
 Number of clusters to match to each track if not doing recover split shower subtraction. More...
 
Gaudi::Property< bool > m_isHLLHC {this, "isHLLHC", false, "Toggle whether we have the HLLHC setup"}
 Toggle whether we have the HLLHC setup. More...
 
Gaudi::Property< bool > m_calcEOverP {this, "CalcEOverP", false, "Toggle EOverP algorithm mode, whereby no charged shower subtraction is performed"}
 Toggle EOverP algorithm mode, whereby no charged shower subtraction is performed. More...
 
Gaudi::Property< double > m_consistencySigmaCut {this, "ConsistencySigmaCut", 1.0, "Parameter that controls whether a track, in a track-cluster system, will be processed by the split shower recovery algorithm"}
 Parameter that controls whether a track, in a track-cluster system, will be processed by the split shower recovery algorithm. More...
 
Gaudi::Property< double > m_subtractionSigmaCut {this, "SubtractionSigmaCut", 1.5, "Parameter that controls whether to use retain remaining calorimeter energy in track-cluster system, after charged shower subtraction"}
 Parameter that controls whether to use retain remaining calorimeter energy in track-cluster system, after charged shower subtraction. More...
 
Gaudi::Property< bool > m_addCPData {this,"addCPData",false,"Toggle whether to decorate FlowElements with addutional data for Combined Performance studies "}
 Toggle whether to decorate eflowRecTrack with addutional data for Combined Performance studies. More...
 
PFCalcRadialEnergyProfiles m_pfCalc {}
 
PFSubtractionStatusSetter m_pfSubtractionStatusSetter {}
 
PFSubtractionEnergyRatioCalculator m_pfSubtractionEnergyRatioCalculator {}
 
eflowSubtract::Subtractor m_subtractor {}
 
ToolHandle< PFEnergyPredictorToolm_NNEnergyPredictorTool {this, "NNEnergyPredictorTool", "","Tool for getting predictiing the energy using an ONNX model "}
 Tool for getting predictiing the energy using an ONNX model. More...
 
Gaudi::Property< bool > m_useNNEnergy {this, "useNNEnergy", false, "Toggle whether we use the neural net energy"}
 Toggle whether we use the neural net energy. More...
 
Gaudi::Property< bool > m_useLegacyEBinIndex {this, "useLegacyEBinIndex", true, "Toggle whether we use the legacy energy bin index"}
 Further discussion about why this flag exists can be found in https://its.cern.ch/jira/browse/ATLJETMET-1692 and https://indico.cern.ch/event/1388633/contributions/5837876/attachments/2809591/4903439/PFlow_EOverP_Feb2024.pdf The Jira report discusses assorted problems with the treatment of energy bin indexes for the lookup of e/p values. More...
 

Detailed Description

Definition at line 33 of file PFSubtractionTool.h.

Constructor & Destructor Documentation

◆ PFSubtractionTool()

PFSubtractionTool::PFSubtractionTool ( const std::string &  type,
const std::string &  name,
const IInterface *  parent 
)

Definition at line 15 of file PFSubtractionTool.cxx.

15  : base_class(type, name, parent),
16  m_binnedParameters(std::make_unique<eflowEEtaBinnedParameters>())
17 {
18 }

◆ ~PFSubtractionTool()

PFSubtractionTool::~PFSubtractionTool ( )
default

Member Function Documentation

◆ canAnnihilate()

bool PFSubtractionTool::canAnnihilate ( double  expectedEnergy,
double  sigma,
double  clusterEnergy 
) const
private

Definition at line 425 of file PFSubtractionTool.cxx.

426 {
427  return clusterEnergy - expectedEnergy < m_subtractionSigmaCut * sigma;
428 }

◆ execute()

void PFSubtractionTool::execute ( eflowCaloObjectContainer theEflowCaloObjectContainer,
eflowRecTrackContainer recTrackContainer,
eflowRecClusterContainer recClusterContainer 
) const

Definition at line 52 of file PFSubtractionTool.cxx.

53 {
54 
55  ATH_MSG_DEBUG("Executing");
56 
57  PFData data;
58  data.caloObjects = theEflowCaloObjectContainer;
59  const PFTrackFiller pfTrackFiller;
62 
63  const PFClusterFiller pfClusterFiller;
66 
67  ATH_MSG_DEBUG("This event has " << data.tracks.size() << " tracks " << data.clusters.size() << " clusters ");
68 
69  unsigned int numMatches = matchAndCreateEflowCaloObj(data);
70 
71  if (msgLvl(MSG::DEBUG)) printAllClusters(*recClusterContainer);
72 
73  if (!m_calcEOverP){
75  else performSubtraction(numMatches,data);
76  }
77  else{
79  }
80 
81 }

◆ finalize()

StatusCode PFSubtractionTool::finalize ( )

Definition at line 458 of file PFSubtractionTool.cxx.

458 { return StatusCode::SUCCESS; }

◆ initialize()

StatusCode PFSubtractionTool::initialize ( )

Definition at line 23 of file PFSubtractionTool.cxx.

24 {
25 
26  ATH_CHECK(m_theEOverPTool.retrieve());
27 
28  ATH_CHECK(m_theEOverPTool->fillBinnedParameters(m_binnedParameters.get()));
29 
31  if (!m_trkpos)
32  {
33  ATH_MSG_ERROR("Failed to get TrackPositionProvider for cluster preselection!");
34  return StatusCode::FAILURE;
35  }
36 
37  //Retrieve track-cluster matching tools
38  ATH_CHECK(m_theMatchingTool.retrieve());
41 
43 
44  //Set the level of the helpers to the same as the tool here
45  m_pfCalc.msg().setLevel(this->msg().level());
46  m_pfSubtractionStatusSetter.msg().setLevel(this->msg().level());
47  m_pfSubtractionEnergyRatioCalculator.msg().setLevel(this->msg().level());
48  m_subtractor.m_facilitator.msg().setLevel(this->msg().level());
49  return StatusCode::SUCCESS;
50 }

◆ isEOverPFail()

bool PFSubtractionTool::isEOverPFail ( double  expectedEnergy,
double  sigma,
double  clusterEnergy 
) const
private

Definition at line 419 of file PFSubtractionTool.cxx.

420 {
421  if ((expectedEnergy == 0) && (clusterEnergy > 0)) return false;
422  return clusterEnergy < expectedEnergy - m_consistencySigmaCut * sigma;
423 }

◆ matchAndCreateEflowCaloObj()

unsigned int PFSubtractionTool::matchAndCreateEflowCaloObj ( PFData data) const
private

This matches ID tracks and CaloClusters, and then creates eflowCaloObjects.

No point to do anything if e/p reference bin does not exist

Add cluster matches needed for pull calculation (in eflowCaloObject::simulateShowers) which is used to determine whether to run the charged shower subtraction or not. / Clusters in both a cone of 0.15 and 0.2 are needed for this. / The clusters in a cone of 0.2 are also used as the matched cluster list for recover split showers mode.

Start loop from nCaloObj, which should be zero on a first pass

Definition at line 83 of file PFSubtractionTool.cxx.

83  {
84 
85  //Counts up how many tracks found at least 1 calorimeter cluster matched to it.
86  unsigned int nMatches(0);
87 
88  /* Cache the original number of eflowCaloObjects, if there were any */
89  const unsigned int nCaloObj = data.caloObjects->size();
90  const EventContext &ctx = Gaudi::Hive::currentContext();
91 
92  /* loop tracks in data.tracks and do matching */
93  for (auto *thisEfRecTrack : data.tracks)
94  {
96  if (!thisEfRecTrack->hasBin()) {
97  std::unique_ptr<eflowCaloObject> thisEflowCaloObject = std::make_unique<eflowCaloObject>();
98  thisEflowCaloObject->addTrack(thisEfRecTrack);
99  data.caloObjects->push_back(std::move(thisEflowCaloObject));
100  continue;
101  }
102 
103  if (msgLvl(MSG::DEBUG))
104  {
105  const xAOD::TrackParticle *track = thisEfRecTrack->getTrack();
106  ATH_MSG_DEBUG("Matching track with e,pt, eta and phi " << track->e() << ", " << track->pt() << ", " << track->eta() << " and " << track->phi());
107  }
108 
109  std::vector<eflowTrackClusterLink*> bestClusters;
110  std::vector<float> deltaRPrime;
111 
112  if (!m_recoverSplitShowers){
117  std::vector<std::pair<eflowRecCluster *, float>> bestClusters_02 = m_theMatchingToolForPull_02->doMatches(thisEfRecTrack, data.clusters, -1);
118  for (auto &matchpair : bestClusters_02)
119  {
120  eflowRecCluster *theCluster = matchpair.first;
121  float distancesq = matchpair.second;
122  eflowTrackClusterLink *trackClusterLink = eflowTrackClusterLink::getInstance(thisEfRecTrack, theCluster, ctx);
123  if (distancesq < 0.15 * 0.15)
124  {
125  // Narrower cone is a subset of the selected clusters
126  // Distance returned is deltaR^2
127  thisEfRecTrack->addAlternativeClusterMatch(trackClusterLink, "cone_015");
128  }
129  thisEfRecTrack->addAlternativeClusterMatch(trackClusterLink, "cone_02");
130  }//loop over bestClusters_02
131 
132  //This matching scheme is used to match the calorimeter cluster(s) to be used in the charged showers subtraction for this track.
133  std::vector<std::pair<eflowRecCluster *, float>> matchedClusters = m_theMatchingTool->doMatches(thisEfRecTrack, data.clusters,m_nClusterMatchesToUse);
134  for (auto thePair : matchedClusters) {
135  bestClusters.push_back(eflowTrackClusterLink::getInstance(thisEfRecTrack, thePair.first, ctx));
136  if (m_addCPData) deltaRPrime.push_back(std::sqrt(thePair.second));
137  }
138  }
139  else {
140  const std::vector<eflowTrackClusterLink*>* matchedClusters_02 = thisEfRecTrack->getAlternativeClusterMatches("cone_02");
141  if (!matchedClusters_02) continue;
142  else bestClusters = *matchedClusters_02;
143  }
144 
145  if (bestClusters.empty()) continue;
146 
147  if (msgLvl(MSG::DEBUG))
148  {
149  for (auto *thisClusterLink : bestClusters ) {
150  xAOD::CaloCluster* thisCluster = thisClusterLink->getCluster()->getCluster();
151  ATH_MSG_DEBUG("Matched this track to cluster with e,pt, eta and phi " << thisCluster->e() << ", " << thisCluster->pt() << ", " << thisCluster->eta() << " and " << thisCluster->phi());
152  }
153  }
154 
155  nMatches++;
156 
157  //loop over the matched calorimeter clusters and associate tracks and clusters to each other as needed.
158  unsigned int linkIndex = 0;
159  for (auto *trkClusLink : bestClusters){
160 
161  eflowRecCluster *thisEFRecCluster = trkClusLink->getCluster();
162 
164  // Look up whether this cluster is intended for recovery
165  if (std::find(data.clusters.begin(), data.clusters.end(), trkClusLink->getCluster()) == data.clusters.end()) {
166  linkIndex++;
167  continue;
168  }
169  }
170 
171  eflowTrackClusterLink *trackClusterLink = eflowTrackClusterLink::getInstance(thisEfRecTrack, thisEFRecCluster, ctx);
172  thisEfRecTrack->addClusterMatch(trackClusterLink);
173  if (m_addCPData) thisEfRecTrack->addDeltaRPrime(deltaRPrime[linkIndex]);
174  thisEFRecCluster->addTrackMatch(trackClusterLink);
175  }
176  linkIndex++;
177  }
178 
179  /* Create 3 types eflowCaloObjects: track-only, cluster-only, track-cluster-link */
180  std::vector<eflowRecCluster *> clusters(data.clusters.begin(), data.clusters.end());
182  unsigned int nCaloObjects = eflowCaloObjectMaker::makeTrkCluCaloObjects(data.tracks, clusters, data.caloObjects);
183  ATH_MSG_DEBUG("Created " << nCaloObjects << " eflowCaloObjects.");
184  if (msgLvl(MSG::DEBUG)){
185  for (auto thisEFlowCaloObject : *(data.caloObjects)){
186  ATH_MSG_DEBUG("This eflowCaloObject has " << thisEFlowCaloObject->nTracks() << " tracks and " << thisEFlowCaloObject->nClusters() << " clusters ");
187  for (unsigned int count = 0; count < thisEFlowCaloObject->nTracks(); count++){
188  const xAOD::TrackParticle* thisTrack = thisEFlowCaloObject->efRecTrack(count)->getTrack();
189  ATH_MSG_DEBUG("Have track with e, pt, eta and phi of " << thisTrack->e() << ", " << thisTrack->pt() << ", " << thisTrack->eta() << " and " << thisTrack->phi());
190  }
191  for (unsigned int count = 0; count < thisEFlowCaloObject->nClusters(); count++){
192  const xAOD::CaloCluster* thisCluster = thisEFlowCaloObject->efRecCluster(count)->getCluster();
193  ATH_MSG_DEBUG("Have cluster with e, pt, eta and phi of " << thisCluster->e() << ", " << thisCluster->pt() << ", " << thisCluster->eta() << " and " << thisCluster->phi());
194  }
195  }
196  }
197 
198  const double gaussianRadius = 0.032;
199  const double gaussianRadiusError = 1.0e-3;
200  const double maximumRadiusSigma = 3.0;
201 
202  eflowLayerIntegrator integrator(gaussianRadius, gaussianRadiusError, maximumRadiusSigma, m_isHLLHC);
203 
205  if (!m_recoverSplitShowers && 0 != nCaloObj) ATH_MSG_WARNING("Not in Split Showers Mode and already have " << nCaloObj << " eflowCaloObjects");
206 
207  //For each eflowCaloObject we calculate the expected energy deposit in the calorimeter and cell ordering for subtraction.
208  for (unsigned int iCalo = nCaloObj; iCalo < data.caloObjects->size(); ++iCalo) {
209  eflowCaloObject* thisEflowCaloObject = data.caloObjects->at(iCalo);
210  thisEflowCaloObject->simulateShower(&integrator, m_binnedParameters.get(), true, m_useNNEnergy ? &(*m_NNEnergyPredictorTool) : nullptr, m_useLegacyEBinIndex);
211  }
212 
213  if (!m_recoverSplitShowers) return nMatches;
214  else return nCaloObj;
215 }

◆ performSubtraction() [1/2]

void PFSubtractionTool::performSubtraction ( const unsigned int &  startingPoint,
PFData data 
) const
private

Definition at line 217 of file PFSubtractionTool.cxx.

217  {
218  unsigned int nEFCaloObs = data.caloObjects->size();
219  for (unsigned int iCalo = startingPoint; iCalo < nEFCaloObs; ++iCalo) {
220  eflowCaloObject* thisEflowCaloObject = data.caloObjects->at(iCalo);
221  this->performSubtraction(*thisEflowCaloObject);
222  }
223 }

◆ performSubtraction() [2/2]

void PFSubtractionTool::performSubtraction ( eflowCaloObject thisEflowCaloObject) const
private

Definition at line 225 of file PFSubtractionTool.cxx.

225  {
226 
227  ATH_MSG_DEBUG("In performSubtraction");
228 
229  unsigned int nClusters = thisEflowCaloObject.nClusters();
230  unsigned int nTrackMatches = thisEflowCaloObject.nTracks();
231 
232  ATH_MSG_DEBUG("Have got an eflowCaloObject with " << nClusters << " clusters and " << nTrackMatches << " track matches");
233 
234  if (msgLevel(MSG::DEBUG)){
235  for (unsigned int iTrack = 0; iTrack < nTrackMatches; ++iTrack){
236  eflowRecTrack* thisTrack = thisEflowCaloObject.efRecTrack(iTrack);
237  ATH_MSG_DEBUG("eflowCaloObject has track with E, pt and eta " << thisTrack->getTrack()->e() << ", " << thisTrack->getTrack()->pt() << " and " << thisTrack->getTrack()->eta());
238  }
239  }
240 
241  //To keep historical behaviour when in recover split showers mode allow tracks with no cluster matches to proceed.
242  if (!m_recoverSplitShowers && nClusters < 1) return;
243 
244  //Need at least one track in this eflowCaloObject to continue.
245  if (nTrackMatches < 1) return;
246 
247  double expectedEnergy = thisEflowCaloObject.getExpectedEnergy();
248  double clusterEnergy = thisEflowCaloObject.getClusterEnergy();
249  double expectedSigma = sqrt(thisEflowCaloObject.getExpectedVariance());
250 
251  /* Check e/p, if on first pass - return if e/p not consistent with expected e/p */
252  if (!m_recoverSplitShowers){
253  if (isEOverPFail(expectedEnergy, expectedSigma, clusterEnergy)) return;
254  }
255 
256  const std::vector<std::pair<eflowTrackClusterLink *, std::pair<float, float>>> &matchedTrackList = thisEflowCaloObject.efRecLink();
257 
258  ATH_MSG_DEBUG("Matched Track List has size " << matchedTrackList.size());
259 
260  if (msgLevel(MSG::DEBUG))
261  {
262  for (unsigned int iTrack = 0; iTrack < nTrackMatches; ++iTrack)
263  {
264  const xAOD::TrackParticle *thisTrack = thisEflowCaloObject.efRecTrack(iTrack)->getTrack();
265  ATH_MSG_DEBUG("eflowCaloObject has track match with E, pt and eta " << thisTrack->e() << ", " << thisTrack->pt() << " and " << thisTrack->eta());
266  }
267  }
268 
269  ATH_MSG_DEBUG("About to perform subtraction for this eflowCaloObject");
270 
271  bool wasAnnihilated = false;
272 
273  //First deal with non-split showers mode
274  if (!m_recoverSplitShowers){
275  /* Check if we can annihilate right away - true if matched cluster has only the expected energy deposit */
276  if (canAnnihilate(expectedEnergy, expectedSigma, clusterEnergy)){
277 
278  wasAnnihilated = true;
279 
280  std::vector<std::pair<xAOD::CaloCluster *, bool>> clusterList;
281  std::map<xAOD::CaloCluster *, double> clusterEnergyMap;
282  unsigned nCluster = thisEflowCaloObject.nClusters();
283  for (unsigned iCluster = 0; iCluster < nCluster; ++iCluster){
284  clusterList.emplace_back(thisEflowCaloObject.efRecCluster(iCluster)->getCluster(), false);
285  }
286 
287  ATH_MSG_DEBUG("We are going to annihilate. ExpectedEnergy, expectedSigma and clusterEnergy are " << expectedEnergy << ", " << expectedSigma << " and " << clusterEnergy);
288  if (msgLevel(MSG::DEBUG))
289  for (auto thisPair : clusterList)
290  ATH_MSG_DEBUG("Annihilating cluster with E and eta " << thisPair.first->e() << " and " << thisPair.first->eta());
291 
293  Subtractor::annihilateClusters(clusterList);
294 
295  if (msgLevel(MSG::DEBUG))
296  for (auto thisPair : clusterList)
297  ATH_MSG_DEBUG("Have Annihilated cluster with E and eta " << thisPair.first->e() << " and " << thisPair.first->eta());
298 
299  /* Flag all tracks in this system as subtracted */
300  for (unsigned iTrack = 0; iTrack < thisEflowCaloObject.nTracks(); ++iTrack){
301  eflowRecTrack *thisEfRecTrack = (matchedTrackList[iTrack].first)->getTrack();
302  if (!thisEfRecTrack->isSubtracted()) thisEfRecTrack->setSubtracted();
303  }
304 
305  }//if can annihilate this track-cluster systems matched cluster
306  }//split shower recovery mode or regular mode where above annihilation was not triggered
307  if (m_recoverSplitShowers || !wasAnnihilated){
308 
309  for (unsigned iTrack = 0; iTrack < thisEflowCaloObject.nTracks(); ++iTrack){
310 
311  eflowRecTrack *thisEfRecTrack = thisEflowCaloObject.efRecTrack(iTrack);
312 
313  ATH_MSG_DEBUG("About to subtract track with e, pt, eta and phi of " << thisEfRecTrack->getTrack()->e() << ", " << thisEfRecTrack->getTrack()->pt() << ", " << thisEfRecTrack->getTrack()->eta() << " and "
314  << thisEfRecTrack->getTrack()->eta());
315 
316  if (!thisEfRecTrack->hasBin()) continue;
317 
318  ATH_MSG_DEBUG("Have bin for this eflowCaloObject");
319 
320  if (thisEfRecTrack->isInDenseEnvironment() && !m_recoverSplitShowers) continue;
321 
322  ATH_MSG_DEBUG("Am not in dense environment for this eflowCaloObject");
323 
324  /* Get matched cluster via Links */
325  std::vector<eflowRecCluster *> matchedClusters;
326  std::vector<eflowTrackClusterLink *> links = thisEfRecTrack->getClusterMatches();
327  matchedClusters.reserve(links.size());
328  for (auto* thisEFlowTrackClusterLink : links)
329  matchedClusters.push_back(thisEFlowTrackClusterLink->getCluster());
331  std::sort(matchedClusters.begin(),
332  matchedClusters.end(),
334 
335  if (msgLvl(MSG::DEBUG)) {
336  for (auto* thisClus : matchedClusters)
338  "Haved matched cluster "
339  << thisClus->getCluster()->index() << " with e,pt, eta and phi of "
340  << thisClus->getCluster()->e() << ", "
341  << thisClus->getCluster()->pt() << ", "
342  << thisClus->getCluster()->eta() << " and "
343  << thisClus->getCluster()->phi() << " will be subtracted");
344  }
345 
346  /* Do subtraction */
347  std::vector<std::pair<xAOD::CaloCluster *, bool>> clusterSubtractionList;
348  clusterSubtractionList.reserve(matchedClusters.size());
349  std::map<xAOD::CaloCluster *, double> clusterEnergyMap;
350  for (auto *thisEFlowRecCluster : matchedClusters){
351  xAOD::CaloCluster *thisCluster = thisEFlowRecCluster->getCluster();
352  clusterSubtractionList.emplace_back(thisCluster, false);
353  clusterEnergyMap[thisCluster] = thisCluster->e();
354  }
355 
356  ATH_MSG_DEBUG("Have filled clusterSubtractionList for this eflowCaloObject");
357 
358  unsigned int trackIndex = thisEfRecTrack->getTrack()->index();
359 
360  //Previously we only checked this in recover split showers, but makes sense to check it in both passes.
361  auto sumClusEnergy = [](double accumulator, std::pair<xAOD::CaloCluster *, bool> thisPair){ return accumulator += thisPair.first->e();};
362  double totalClusterEnergy = std::accumulate(clusterSubtractionList.begin(),clusterSubtractionList.end(),0.0,sumClusEnergy);
363 
364  /* Check if we can annihilate right away - true if matched cluster has only the expected energy deposit */
365  if(canAnnihilate(thisEfRecTrack->getEExpect(),sqrt(thisEfRecTrack->getVarEExpect()),totalClusterEnergy)){
366 
367  if (msgLevel(MSG::DEBUG))
368  for (auto thisPair : clusterSubtractionList)
369  ATH_MSG_DEBUG("Annihilating cluster with E and eta " << thisPair.first->e() << " and " << thisPair.first->eta());
370 
371  Subtractor::annihilateClusters(clusterSubtractionList);
372  //Now we should mark all of these clusters as being subtracted
373  //Now need to mark which clusters were modified in the subtraction procedure
374  std::vector<std::pair<float, float>> clusterSubtractedEnergyRatios;
375  m_pfSubtractionEnergyRatioCalculator.calculateSubtractedEnergyRatiosForAnnih(clusterSubtractionList, clusterEnergyMap, clusterSubtractedEnergyRatios);
376  m_pfSubtractionStatusSetter.markSubtractionStatus(clusterSubtractionList, clusterSubtractedEnergyRatios, thisEflowCaloObject, trackIndex);
377  }
378  else
379  {
380 
381  /* Subtract the track from all matched clusters */
382  m_subtractor.subtractTracksFromClusters(thisEfRecTrack, clusterSubtractionList);
383 
384  //recalculate total cluster energy from the clusters afer subtraction
385  totalClusterEnergy = std::accumulate(clusterSubtractionList.begin(),clusterSubtractionList.end(),0.0,sumClusEnergy);
386 
387  /* Annihilate the cluster(s) if the remnant is small (i.e. below k*sigma) */
388  if (canAnnihilate(0.0,sqrt(thisEfRecTrack->getVarEExpect()), totalClusterEnergy)){
389 
390  if (msgLevel(MSG::DEBUG))
391  for (auto thisPair : clusterSubtractionList){
392  ATH_MSG_DEBUG("Annihilating remnant cluster with E and eta " << thisPair.first->e() << " and " << thisPair.first->eta());
393  }
394  eflowSubtract::Subtractor::annihilateClusters(clusterSubtractionList);
395  //Now we should mark all of these clusters as being subtracted
396  std::vector<std::pair<float, float>> clusterSubtractedEnergyRatios;
397  m_pfSubtractionEnergyRatioCalculator.calculateSubtractedEnergyRatiosForAnnih(clusterSubtractionList, clusterEnergyMap, clusterSubtractedEnergyRatios);
398  m_pfSubtractionStatusSetter.markSubtractionStatus(clusterSubtractionList, clusterSubtractedEnergyRatios, thisEflowCaloObject, trackIndex);
399  }//if remove the remnant after cell by cell subtraction
400  else
401  {
402  std::vector<std::pair<float, float>> clusterSubtractedEnergyRatios;
403  m_pfSubtractionEnergyRatioCalculator.calculateSubtractedEnergyRatios(clusterSubtractionList, clusterEnergyMap, clusterSubtractedEnergyRatios);
404  m_pfSubtractionStatusSetter.markSubtractionStatus(clusterSubtractionList, clusterSubtractedEnergyRatios, thisEflowCaloObject, trackIndex);
405  }//if don't remove the remnant after cell by cell subtraction
406 
407  }//if not annihilating, and instead subtracting cell by cell
408 
409  ATH_MSG_DEBUG("Have subtracted charged shower for this eflowRecTrack");
410 
411  /* Flag tracks as subtracted */
412  if (!thisEfRecTrack->isSubtracted()) thisEfRecTrack->setSubtracted();
413 
414  }//loop over tracks in eflowCaloObject
415  }//cell by cell subtraction
416 
417 }

◆ printAllClusters()

void PFSubtractionTool::printAllClusters ( const eflowRecClusterContainer recClusterContainer) const
private

Definition at line 442 of file PFSubtractionTool.cxx.

442  {
443 
444  for ( const auto *thisEFRecCluster : recClusterContainer){
445  if (thisEFRecCluster->getTrackMatches().empty()) {
446  ATH_MSG_DEBUG("Isolated" << printCluster(thisEFRecCluster->getCluster()));
447  } else {
448  ATH_MSG_DEBUG("Matched" << printCluster(thisEFRecCluster->getCluster()));
449  std::vector<eflowTrackClusterLink*> theTrackLinks = thisEFRecCluster->getTrackMatches();
450  for ( auto *thisTrack : theTrackLinks){
451  ATH_MSG_DEBUG("Matched" << printTrack(thisTrack->getTrack()->getTrack()));
452  }
453  }
454  }
455 }

◆ printCluster()

std::string PFSubtractionTool::printCluster ( const xAOD::CaloCluster cluster)
staticprivate

Definition at line 436 of file PFSubtractionTool.cxx.

436  {
437  std::stringstream result;
438  result << " cluster with E, eta and phi of " << cluster->e() << ", " << cluster->eta() << " and " << cluster->phi();
439  return result.str();
440 }

◆ printTrack()

std::string PFSubtractionTool::printTrack ( const xAOD::TrackParticle track)
staticprivate

Definition at line 430 of file PFSubtractionTool.cxx.

430  {
431  std::stringstream result;
432  result << " track with E, eta and phi "<< track->e() << ", " << track->eta() << " and " << track->phi();
433  return result.str();
434 }

Member Data Documentation

◆ m_addCPData

Gaudi::Property<bool> PFSubtractionTool::m_addCPData {this,"addCPData",false,"Toggle whether to decorate FlowElements with addutional data for Combined Performance studies "}
private

Toggle whether to decorate eflowRecTrack with addutional data for Combined Performance studies.

Definition at line 94 of file PFSubtractionTool.h.

◆ m_binnedParameters

std::unique_ptr<eflowEEtaBinnedParameters> PFSubtractionTool::m_binnedParameters
private

Definition at line 63 of file PFSubtractionTool.h.

◆ m_calcEOverP

Gaudi::Property<bool> PFSubtractionTool::m_calcEOverP {this, "CalcEOverP", false, "Toggle EOverP algorithm mode, whereby no charged shower subtraction is performed"}
private

Toggle EOverP algorithm mode, whereby no charged shower subtraction is performed.

Definition at line 85 of file PFSubtractionTool.h.

◆ m_consistencySigmaCut

Gaudi::Property<double> PFSubtractionTool::m_consistencySigmaCut {this, "ConsistencySigmaCut", 1.0, "Parameter that controls whether a track, in a track-cluster system, will be processed by the split shower recovery algorithm"}
private

Parameter that controls whether a track, in a track-cluster system, will be processed by the split shower recovery algorithm.

Definition at line 88 of file PFSubtractionTool.h.

◆ m_isHLLHC

Gaudi::Property<bool> PFSubtractionTool::m_isHLLHC {this, "isHLLHC", false, "Toggle whether we have the HLLHC setup"}
private

Toggle whether we have the HLLHC setup.

Definition at line 82 of file PFSubtractionTool.h.

◆ m_nClusterMatchesToUse

Gaudi::Property<int> PFSubtractionTool::m_nClusterMatchesToUse {this, "nClusterMatchesToUse", 1, "Number of clusters to match to each track"}
private

Number of clusters to match to each track if not doing recover split shower subtraction.

Definition at line 79 of file PFSubtractionTool.h.

◆ m_NNEnergyPredictorTool

ToolHandle<PFEnergyPredictorTool> PFSubtractionTool::m_NNEnergyPredictorTool {this, "NNEnergyPredictorTool", "","Tool for getting predictiing the energy using an ONNX model "}
private

Tool for getting predictiing the energy using an ONNX model.

Definition at line 103 of file PFSubtractionTool.h.

◆ m_pfCalc

PFCalcRadialEnergyProfiles PFSubtractionTool::m_pfCalc {}
private

Definition at line 97 of file PFSubtractionTool.h.

◆ m_pfSubtractionEnergyRatioCalculator

PFSubtractionEnergyRatioCalculator PFSubtractionTool::m_pfSubtractionEnergyRatioCalculator {}
private

Definition at line 99 of file PFSubtractionTool.h.

◆ m_pfSubtractionStatusSetter

PFSubtractionStatusSetter PFSubtractionTool::m_pfSubtractionStatusSetter {}
private

Definition at line 98 of file PFSubtractionTool.h.

◆ m_recoverSplitShowers

Gaudi::Property<bool> PFSubtractionTool::m_recoverSplitShowers {this,"RecoverSplitShowers",false,"Toggle whether we are recovering split showers or not"}
private

Toggle whether we are recovering split showers or not.

Definition at line 76 of file PFSubtractionTool.h.

◆ m_subtractionSigmaCut

Gaudi::Property<double> PFSubtractionTool::m_subtractionSigmaCut {this, "SubtractionSigmaCut", 1.5, "Parameter that controls whether to use retain remaining calorimeter energy in track-cluster system, after charged shower subtraction"}
private

Parameter that controls whether to use retain remaining calorimeter energy in track-cluster system, after charged shower subtraction.

Definition at line 91 of file PFSubtractionTool.h.

◆ m_subtractor

eflowSubtract::Subtractor PFSubtractionTool::m_subtractor {}
private

Definition at line 100 of file PFSubtractionTool.h.

◆ m_theEOverPTool

ToolHandle<IEFlowCellEOverPTool> PFSubtractionTool::m_theEOverPTool {this, "eflowCellEOverPTool", "eflowCellEOverPTool", "Energy Flow E/P Values and Shower Parameters Tool"}
private

Tool for getting e/p values and hadronic shower cell ordering principle parameters.

Definition at line 61 of file PFSubtractionTool.h.

◆ m_theMatchingTool

ToolHandle<PFTrackClusterMatchingTool> PFSubtractionTool::m_theMatchingTool {this, "PFTrackClusterMatchingTool", "PFTrackClusterMatchingTool/CalObjBldMatchingTool", "The track-cluster matching tool"}
private

Default track-cluster matching tool.

Definition at line 69 of file PFSubtractionTool.h.

◆ m_theMatchingToolForPull_015

ToolHandle<PFTrackClusterMatchingTool> PFSubtractionTool::m_theMatchingToolForPull_015 {this, "PFTrackClusterMatchingTool_015", "PFTrackClusterMatchingTool/PFPullMatchingTool_015", "The 0.15 track-cluster matching tool to calculate the pull"}
private

Definition at line 72 of file PFSubtractionTool.h.

◆ m_theMatchingToolForPull_02

ToolHandle<PFTrackClusterMatchingTool> PFSubtractionTool::m_theMatchingToolForPull_02 {this, "PFTrackClusterMatchingTool_02", "PFTrackClusterMatchingTool/PFPullMatchingTool_02", "The 0.2 track-cluster matching tool to calculate the pull"}
private

Definition at line 73 of file PFSubtractionTool.h.

◆ m_trkpos

std::unique_ptr<PFMatch::TrackEtaPhiInFixedLayersProvider> PFSubtractionTool::m_trkpos
private

Track position provider to be used to preselect clusters.

Definition at line 66 of file PFSubtractionTool.h.

◆ m_useLegacyEBinIndex

Gaudi::Property<bool> PFSubtractionTool::m_useLegacyEBinIndex {this, "useLegacyEBinIndex", true, "Toggle whether we use the legacy energy bin index"}
private

Further discussion about why this flag exists can be found in https://its.cern.ch/jira/browse/ATLJETMET-1692 and https://indico.cern.ch/event/1388633/contributions/5837876/attachments/2809591/4903439/PFlow_EOverP_Feb2024.pdf The Jira report discusses assorted problems with the treatment of energy bin indexes for the lookup of e/p values.

In order to not change the behaviour of produciton code a legacy option is introduced to allow us to fix the problem in future iterations of e/p derivations.s

Definition at line 113 of file PFSubtractionTool.h.

◆ m_useNNEnergy

Gaudi::Property<bool> PFSubtractionTool::m_useNNEnergy {this, "useNNEnergy", false, "Toggle whether we use the neural net energy"}
private

Toggle whether we use the neural net energy.

Definition at line 106 of file PFSubtractionTool.h.


The documentation for this class was generated from the following files:
eflowRecCluster
This class extends the information about a xAOD::CaloCluster.
Definition: eflowRecCluster.h:40
xAOD::CaloCluster_v1::phi
virtual double phi() const
The azimuthal angle ( ) of the particle.
Definition: CaloCluster_v1.cxx:256
eflowRecCluster::SortDescendingPt
Definition: eflowRecCluster.h:124
xAOD::TrackParticle_v1::pt
virtual double pt() const override final
The transverse momentum ( ) of the particle.
Definition: TrackParticle_v1.cxx:73
eflowCaloObject::nClusters
unsigned nClusters() const
Definition: eflowCaloObject.h:59
data
char data[hepevt_bytes_allocation_ATLAS]
Definition: HepEvt.cxx:11
eflowSubtract::Subtractor::subtractTracksFromClusters
void subtractTracksFromClusters(eflowRecTrack *efRecTrack, std::vector< std::pair< xAOD::CaloCluster *, bool >> &clusterSubtractionList) const
Definition: eflowSubtractor.cxx:27
eflowCaloObject::getExpectedEnergy
double getExpectedEnergy() const
Definition: eflowCaloObject.cxx:40
pdg_comparison.sigma
sigma
Definition: pdg_comparison.py:324
eflowLayerIntegrator
This class calculates the LHED (Layer of Highest Energy Density) in a cluster or group of clusters.
Definition: eflowLayerIntegrator.h:35
get_generator_info.result
result
Definition: get_generator_info.py:21
eflowCaloObject::efRecLink
const std::vector< std::pair< eflowTrackClusterLink *, std::pair< float, float > > > & efRecLink() const
Definition: eflowCaloObject.h:64
PFSubtractionTool::m_isHLLHC
Gaudi::Property< bool > m_isHLLHC
Toggle whether we have the HLLHC setup.
Definition: PFSubtractionTool.h:82
find
std::string find(const std::string &s)
return a remapped string
Definition: hcg.cxx:135
PFSubtractionTool::m_subtractor
eflowSubtract::Subtractor m_subtractor
Definition: PFSubtractionTool.h:100
eflowRecTrack::isInDenseEnvironment
bool isInDenseEnvironment() const
Definition: eflowRecTrack.h:116
PFClusterFiller::fillClustersToRecover
static void fillClustersToRecover(PFData &data)
Definition: PFClusterFiller.cxx:5
eflowRecCluster::addTrackMatch
void addTrackMatch(eflowTrackClusterLink *trackMatch)
Definition: eflowRecCluster.h:69
PFSubtractionEnergyRatioCalculator::calculateSubtractedEnergyRatios
void calculateSubtractedEnergyRatios(const std::vector< std::pair< xAOD::CaloCluster *, bool >> &clusterSubtractionList, std::map< xAOD::CaloCluster *, double > &clusterEnergyMap, std::vector< std::pair< float, float >> &clusterSubtractedEnergyRatios) const
For each xAOD::CaloCluster in clusterSubtractionList we calculate the ratio of new to old energy afte...
Definition: PFSubtractionEnergyRatioCalculator.cxx:13
xAOD::TrackParticle_v1::eta
virtual double eta() const override final
The pseudorapidity ( ) of the particle.
Definition: TrackParticle_v1.cxx:77
PFSubtractionTool::m_NNEnergyPredictorTool
ToolHandle< PFEnergyPredictorTool > m_NNEnergyPredictorTool
Tool for getting predictiing the energy using an ONNX model.
Definition: PFSubtractionTool.h:103
PFSubtractionStatusSetter::markAllTracksAnnihStatus
void markAllTracksAnnihStatus(eflowCaloObject &thisEflowCaloObject) const
Set the ratio of new to old cluster energy, to zero, for all cluster matched to all tracks attached t...
Definition: PFSubtractionStatusSetter.cxx:71
accumulate
bool accumulate(AccumulateMap &map, std::vector< module_t > const &modules, FPGATrackSimMatrixAccumulator const &acc)
Accumulates an accumulator (e.g.
Definition: FPGATrackSimMatrixAccumulator.cxx:22
PFSubtractionTool::m_consistencySigmaCut
Gaudi::Property< double > m_consistencySigmaCut
Parameter that controls whether a track, in a track-cluster system, will be processed by the split sh...
Definition: PFSubtractionTool.h:88
eflowRecTrack::hasBin
bool hasBin() const
Definition: eflowRecTrack.h:73
PFSubtractionTool::m_trkpos
std::unique_ptr< PFMatch::TrackEtaPhiInFixedLayersProvider > m_trkpos
Track position provider to be used to preselect clusters.
Definition: PFSubtractionTool.h:66
PFSubtractionTool::matchAndCreateEflowCaloObj
unsigned int matchAndCreateEflowCaloObj(PFData &data) const
This matches ID tracks and CaloClusters, and then creates eflowCaloObjects.
Definition: PFSubtractionTool.cxx:83
eflowCaloObject
An internal EDM object which stores information about systems of associated tracks and calorimeter cl...
Definition: eflowCaloObject.h:33
XMLtoHeader.count
count
Definition: XMLtoHeader.py:85
PFMatch::TrackPositionFactory::Get
static std::unique_ptr< IPositionProvider > Get(const std::string &positionType)
Definition: PFMatchPositions.h:95
python.iconfTool.models.loaders.level
level
Definition: loaders.py:20
eflowCaloObject::getExpectedVariance
double getExpectedVariance() const
Definition: eflowCaloObject.cxx:48
eflowCaloObject::addTrack
void addTrack(eflowRecTrack *track)
Definition: eflowCaloObject.h:39
eflowRecTrack
This class extends the information about a xAOD::Track.
Definition: eflowRecTrack.h:45
PFTrackFiller
Definition: PFTrackFiller.h:7
PFSubtractionTool::m_pfSubtractionStatusSetter
PFSubtractionStatusSetter m_pfSubtractionStatusSetter
Definition: PFSubtractionTool.h:98
eflowRecTrack::setSubtracted
void setSubtracted()
Definition: eflowRecTrack.h:81
eflowRecTrack::getClusterMatches
const std::vector< eflowTrackClusterLink * > & getClusterMatches() const
Definition: eflowRecTrack.h:66
PFSubtractionTool::m_theEOverPTool
ToolHandle< IEFlowCellEOverPTool > m_theEOverPTool
Tool for getting e/p values and hadronic shower cell ordering principle parameters.
Definition: PFSubtractionTool.h:61
PFSubtractionTool::m_useNNEnergy
Gaudi::Property< bool > m_useNNEnergy
Toggle whether we use the neural net energy.
Definition: PFSubtractionTool.h:106
xAOD::CaloCluster_v1
Description of a calorimeter cluster.
Definition: CaloCluster_v1.h:59
eflowCaloObject::efRecTrack
const eflowRecTrack * efRecTrack(int i) const
Definition: eflowCaloObject.h:51
PFSubtractionTool::m_nClusterMatchesToUse
Gaudi::Property< int > m_nClusterMatchesToUse
Number of clusters to match to each track if not doing recover split shower subtraction.
Definition: PFSubtractionTool.h:79
PFSubtractionTool::printAllClusters
void printAllClusters(const eflowRecClusterContainer &recClusterContainer) const
Definition: PFSubtractionTool.cxx:442
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
PFSubtractionTool::isEOverPFail
bool isEOverPFail(double expectedEnergy, double sigma, double clusterEnergy) const
Definition: PFSubtractionTool.cxx:419
xAOD::CaloCluster_v1::eta
virtual double eta() const
The pseudorapidity ( ) of the particle.
Definition: CaloCluster_v1.cxx:251
PFSubtractionTool::m_pfCalc
PFCalcRadialEnergyProfiles m_pfCalc
Definition: PFSubtractionTool.h:97
PFSubtractionTool::performSubtraction
void performSubtraction(const unsigned int &startingPoint, PFData &data) const
Definition: PFSubtractionTool.cxx:217
eflowRecTrack::isSubtracted
bool isSubtracted() const
Definition: eflowRecTrack.h:79
DMTest::links
links
Definition: CLinks_v1.cxx:22
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
PFSubtractionTool::m_theMatchingToolForPull_02
ToolHandle< PFTrackClusterMatchingTool > m_theMatchingToolForPull_02
Definition: PFSubtractionTool.h:73
PFClusterFiller
Definition: PFClusterFiller.h:7
PFCalcRadialEnergyProfiles::calculate
void calculate(const PFData &data) const
Definition: PFCalcRadialEnergyProfiles.cxx:11
PFSubtractionStatusSetter::markSubtractionStatus
void markSubtractionStatus(const std::vector< std::pair< xAOD::CaloCluster *, bool >> &clusterList, std::vector< std::pair< float, float >> &clusterSubtractedEnergyRatios, eflowCaloObject &thisEflowCaloObject, unsigned int trackIndex) const
Set the ratio of new to old cluster energy for each cluster matched to a track with trackIndex.
Definition: PFSubtractionStatusSetter.cxx:17
PFSubtractionEnergyRatioCalculator::calculateSubtractedEnergyRatiosForAnnih
void calculateSubtractedEnergyRatiosForAnnih(const std::vector< std::pair< xAOD::CaloCluster *, bool >> &clusterSubtractionList, std::map< xAOD::CaloCluster *, double > &clusterEnergyMap, std::vector< std::pair< float, float >> &clusterSubtractedEnergyRatios) const
If we have decided to annihiliate all clusters in clusterSubtractionList we use this function to set ...
Definition: PFSubtractionEnergyRatioCalculator.cxx:49
eflowRecTrack::getEExpect
double getEExpect() const
Definition: eflowRecTrack.h:97
asg::AsgMessaging::msg
MsgStream & msg() const
The standard message stream.
Definition: AsgMessaging.cxx:49
PFSubtractionTool::m_calcEOverP
Gaudi::Property< bool > m_calcEOverP
Toggle EOverP algorithm mode, whereby no charged shower subtraction is performed.
Definition: PFSubtractionTool.h:85
test_pyathena.parent
parent
Definition: test_pyathena.py:15
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
eflowRecCluster::getCluster
xAOD::CaloCluster * getCluster()
Definition: eflowRecCluster.h:49
eflowCaloObject::nTracks
unsigned nTracks() const
Definition: eflowCaloObject.h:53
SG::AuxElement::index
size_t index() const
Return the index of this element within its container.
eflowSubtract::Subtractor::m_facilitator
eflowCellSubtractionFacilitator m_facilitator
Definition: eflowSubtractor.h:56
PFData
Definition: PFData.h:11
PFSubtractionTool::m_pfSubtractionEnergyRatioCalculator
PFSubtractionEnergyRatioCalculator m_pfSubtractionEnergyRatioCalculator
Definition: PFSubtractionTool.h:99
PFSubtractionTool::m_recoverSplitShowers
Gaudi::Property< bool > m_recoverSplitShowers
Toggle whether we are recovering split showers or not.
Definition: PFSubtractionTool.h:76
PFSubtractionTool::m_useLegacyEBinIndex
Gaudi::Property< bool > m_useLegacyEBinIndex
Further discussion about why this flag exists can be found in https://its.cern.ch/jira/browse/ATLJETM...
Definition: PFSubtractionTool.h:113
PFSubtractionTool::printTrack
static std::string printTrack(const xAOD::TrackParticle *track)
Definition: PFSubtractionTool.cxx:430
xAOD::CaloCluster_v1::pt
virtual double pt() const
The transverse momentum ( ) of the particle (negative for negative-energy clusters)
Definition: CaloCluster_v1.cxx:247
eflowRecTrack::getTrack
const xAOD::TrackParticle * getTrack() const
Definition: eflowRecTrack.h:53
python.EventInfoMgtInit.release
release
Definition: EventInfoMgtInit.py:24
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:195
eflowCaloObjectMaker::makeTrkCluCaloObjects
static unsigned int makeTrkCluCaloObjects(eflowRecTrackContainer *eflowTrackContainer, eflowRecClusterContainer *eflowClusterContainer, eflowCaloObjectContainer *caloObjectContainer)
Definition: eflowCaloObjectMaker.cxx:25
PFSubtractionTool::m_subtractionSigmaCut
Gaudi::Property< double > m_subtractionSigmaCut
Parameter that controls whether to use retain remaining calorimeter energy in track-cluster system,...
Definition: PFSubtractionTool.h:91
PFClusterFiller::fillClustersToConsider
static void fillClustersToConsider(PFData &data, eflowRecClusterContainer &recClusterContainer)
Definition: PFClusterFiller.cxx:25
xAOD::TrackParticle_v1::e
virtual double e() const override final
The total energy of the particle.
Definition: TrackParticle_v1.cxx:109
PFSubtractionTool::canAnnihilate
bool canAnnihilate(double expectedEnergy, double sigma, double clusterEnergy) const
Definition: PFSubtractionTool.cxx:425
PFTrackFiller::fillTracksToConsider
static void fillTracksToConsider(PFData &data, eflowRecTrackContainer &recTrackContainer)
Definition: PFTrackFiller.cxx:57
eflowCaloObject::simulateShower
void simulateShower(eflowLayerIntegrator *integrator, const eflowEEtaBinnedParameters *binnedParameters, bool useUpdated2015ChargedShowerSubtraction, const PFEnergyPredictorTool *energyP, bool useLegacyEnergyBinIndexing)
Definition: eflowCaloObject.cxx:64
PFSubtractionTool::m_theMatchingTool
ToolHandle< PFTrackClusterMatchingTool > m_theMatchingTool
Default track-cluster matching tool.
Definition: PFSubtractionTool.h:69
PFSubtractionTool::printCluster
static std::string printCluster(const xAOD::CaloCluster *cluster)
Definition: PFSubtractionTool.cxx:436
std::sort
void sort(typename std::reverse_iterator< DataModel_detail::iterator< DVL > > beg, typename std::reverse_iterator< DataModel_detail::iterator< DVL > > end, const Compare &comp)
Specialization of sort for DataVector/List.
Definition: DVL_algorithms.h:623
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
eflowCaloObject::efRecCluster
const eflowRecCluster * efRecCluster(int i) const
Definition: eflowCaloObject.h:57
eflowRecTrack::getVarEExpect
double getVarEExpect() const
Definition: eflowRecTrack.h:98
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
DEBUG
#define DEBUG
Definition: page_access.h:11
RunTileMonitoring.clusters
clusters
Definition: RunTileMonitoring.py:133
PFMatch::TrackEtaPhiInFixedLayersProvider
Definition: PFMatchPositions.h:76
PFSubtractionTool::m_binnedParameters
std::unique_ptr< eflowEEtaBinnedParameters > m_binnedParameters
Definition: PFSubtractionTool.h:63
PFSubtractionTool::m_theMatchingToolForPull_015
ToolHandle< PFTrackClusterMatchingTool > m_theMatchingToolForPull_015
Definition: PFSubtractionTool.h:72
eflowCaloObject::getClusterEnergy
double getClusterEnergy() const
Definition: eflowCaloObject.cxx:56
egammaParameters::linkIndex
@ linkIndex
link index for multiple track and vertex matches
Definition: egammaParamDefs.h:574
xAOD::track
@ track
Definition: TrackingPrimitives.h:512
xAOD::TrackParticle_v1
Class describing a TrackParticle.
Definition: TrackParticle_v1.h:43
PFTrackFiller::fillTracksToRecover
static void fillTracksToRecover(PFData &data)
Definition: PFTrackFiller.cxx:5
PFSubtractionTool::m_addCPData
Gaudi::Property< bool > m_addCPData
Toggle whether to decorate eflowRecTrack with addutional data for Combined Performance studies.
Definition: PFSubtractionTool.h:94
python.AutoConfigFlags.msg
msg
Definition: AutoConfigFlags.py:7
xAOD::CaloCluster_v1::e
virtual double e() const
The total energy of the particle.
Definition: CaloCluster_v1.cxx:265
xAOD::TrackParticle_v1::phi
virtual double phi() const override final
The azimuthal angle ( ) of the particle (has range to .)
eflowSubtract::Subtractor::annihilateClusters
static void annihilateClusters(std::vector< std::pair< xAOD::CaloCluster *, bool >> &clusters)
Definition: eflowSubtractor.cxx:78