CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Private Attributes
reco::TauImpactParameterInfo Class Reference

#include <TauImpactParameterInfo.h>

Public Member Functions

virtual TauImpactParameterInfoclone () const
 
float discriminator (double, double, double, bool, bool) const
 
float discriminator () const
 
const IsolatedTauTagInfoRefgetIsolatedTauTag () const
 
const TauImpactParameterTrackDatagetTrackData (const reco::TrackRef &) const
 
void setIsolatedTauTag (const IsolatedTauTagInfoRef &)
 
void storeTrackData (const reco::TrackRef &, const TauImpactParameterTrackData &)
 
 TauImpactParameterInfo ()
 
virtual ~TauImpactParameterInfo ()
 

Private Attributes

IsolatedTauTagInfoRef isolatedTaus
 
TrackTauImpactParameterAssociationCollection trackDataMap
 

Detailed Description

Definition at line 22 of file TauImpactParameterInfo.h.

Constructor & Destructor Documentation

reco::TauImpactParameterInfo::TauImpactParameterInfo ( )
inline

Definition at line 24 of file TauImpactParameterInfo.h.

Referenced by clone().

24 {}
virtual reco::TauImpactParameterInfo::~TauImpactParameterInfo ( )
inlinevirtual

Definition at line 25 of file TauImpactParameterInfo.h.

25 {}

Member Function Documentation

virtual TauImpactParameterInfo* reco::TauImpactParameterInfo::clone ( void  ) const
inlinevirtual

Definition at line 27 of file TauImpactParameterInfo.h.

References TauImpactParameterInfo().

float reco::TauImpactParameterInfo::discriminator ( double  ip_min,
double  ip_max,
double  sip_min,
bool  use_sign,
bool  use3D 
) const

Definition at line 8 of file TauImpactParameterInfo.cc.

References MuTauSkim_cff::discriminator, reco::TauImpactParameterTrackData::ip3D, edm::Ref< C, T, F >::isNull(), Measurement1D::significance(), reco::TauImpactParameterTrackData::transverseIp, and Measurement1D::value().

Referenced by ImpactParameterAlgorithm::tag().

9  {
10  double discriminator = isolatedTaus->discriminator();
11 
12  const TrackRef leadingTrack = isolatedTaus->leadingSignalTrack(0.4, 1.);
13 
14  if (!leadingTrack.isNull()) {
15  const TauImpactParameterTrackData* ipData = getTrackData(leadingTrack);
16  Measurement1D ip = ipData->transverseIp;
17  if (use3D)
18  ip = ipData->ip3D;
19 
20  if (ip.value() < ip_min || ip.value() > ip_max || ip.significance() < sip_min) {
21  discriminator = 0;
22  }
23  }
24  return discriminator;
25 }
bool isNull() const
Checks for null.
Definition: Ref.h:235
double significance() const
Definition: Measurement1D.h:29
IsolatedTauTagInfoRef isolatedTaus
const TauImpactParameterTrackData * getTrackData(const reco::TrackRef &) const
double value() const
Definition: Measurement1D.h:25
float reco::TauImpactParameterInfo::discriminator ( ) const

Definition at line 26 of file TauImpactParameterInfo.cc.

26  {
27  //default discriminator: returns the value of the discriminator of the jet tag
28  return isolatedTaus->discriminator();
29 }
IsolatedTauTagInfoRef isolatedTaus
const IsolatedTauTagInfoRef & reco::TauImpactParameterInfo::getIsolatedTauTag ( ) const

Definition at line 49 of file TauImpactParameterInfo.cc.

49 { return isolatedTaus; }
IsolatedTauTagInfoRef isolatedTaus
const reco::TauImpactParameterTrackData * TauImpactParameterInfo::getTrackData ( const reco::TrackRef trackRef) const

Definition at line 31 of file TauImpactParameterInfo.cc.

References edm::AssociationMap< edm::OneToValue< reco::TrackCollection, reco::TauImpactParameterTrackData > >::const_iterator.

31  {
33 
34  if (iter != trackDataMap.end())
35  return &(iter->val);
36 
37  return nullptr; // if track not found return 0
38 }
const_iterator end() const
last iterator over the map (read only)
const_iterator find(const key_type &k) const
find element with specified reference key
TrackTauImpactParameterAssociationCollection trackDataMap
void reco::TauImpactParameterInfo::setIsolatedTauTag ( const IsolatedTauTagInfoRef isolationRef)

Definition at line 45 of file TauImpactParameterInfo.cc.

Referenced by ImpactParameterAlgorithm::tag().

45  {
46  isolatedTaus = isolationRef;
47 }
IsolatedTauTagInfoRef isolatedTaus
void reco::TauImpactParameterInfo::storeTrackData ( const reco::TrackRef trackRef,
const TauImpactParameterTrackData trackData 
)

Definition at line 40 of file TauImpactParameterInfo.cc.

Referenced by ImpactParameterAlgorithm::tag().

41  {
42  trackDataMap.insert(trackRef, trackData);
43 }
void insert(const key_type &k, const data_type &v)
insert an association
TrackTauImpactParameterAssociationCollection trackDataMap

Member Data Documentation

IsolatedTauTagInfoRef reco::TauImpactParameterInfo::isolatedTaus
private

Definition at line 40 of file TauImpactParameterInfo.h.

TrackTauImpactParameterAssociationCollection reco::TauImpactParameterInfo::trackDataMap
private

Definition at line 39 of file TauImpactParameterInfo.h.