CMS 3D CMS Logo

Functions
MatchingUtils.h File Reference

Go to the source code of this file.

Functions

template<class C1 , class C2 >
bool matchByCommonParentSuperClusterRef (const C1 &c1, const C2 &c2)
 
template<class C1 , class C2 >
bool matchByCommonSourceCandidatePtr (const C1 &c1, const C2 &c2)
 

Function Documentation

◆ matchByCommonParentSuperClusterRef()

template<class C1 , class C2 >
bool matchByCommonParentSuperClusterRef ( const C1 &  c1,
const C2 &  c2 
)

Definition at line 21 of file MatchingUtils.h.

21  {
22  auto c1s = c1.parentSuperCluster();
23  auto c2s = c2.parentSuperCluster();
24  return (c1s == c2s);
25 }

References alignmentValidation::c1.

Referenced by PATObjectCrossLinker::matchElectronToPhoton(), and EGMEnergyVarProducer< T >::produce().

◆ matchByCommonSourceCandidatePtr()

template<class C1 , class C2 >
bool matchByCommonSourceCandidatePtr ( const C1 &  c1,
const C2 &  c2 
)

Definition at line 9 of file MatchingUtils.h.

9  {
10  for (unsigned int i1 = 0; i1 < c1.numberOfSourceCandidatePtrs(); i1++) {
11  auto c1s = c1.sourceCandidatePtr(i1);
12  for (unsigned int i2 = 0; i2 < c2.numberOfSourceCandidatePtrs(); i2++) {
13  if (c2.sourceCandidatePtr(i2) == c1s)
14  return true;
15  }
16  }
17  return false;
18 }

References alignmentValidation::c1, testProducerWithPsetDescEmpty_cfi::i1, and testProducerWithPsetDescEmpty_cfi::i2.

Referenced by PATObjectCrossLinker::matchOneToMany(), LeptonInJetProducer< T >::produce(), and LeptonJetVarProducer< T >::produce().

testProducerWithPsetDescEmpty_cfi.i2
i2
Definition: testProducerWithPsetDescEmpty_cfi.py:46
testProducerWithPsetDescEmpty_cfi.i1
i1
Definition: testProducerWithPsetDescEmpty_cfi.py:45
alignmentValidation.c1
c1
do drawing
Definition: alignmentValidation.py:1025