test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros 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 26 of file TauImpactParameterInfo.h.

Constructor & Destructor Documentation

reco::TauImpactParameterInfo::TauImpactParameterInfo ( )
inline

Definition at line 28 of file TauImpactParameterInfo.h.

Referenced by clone().

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

Definition at line 29 of file TauImpactParameterInfo.h.

29 {}

Member Function Documentation

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

Definition at line 31 of file TauImpactParameterInfo.h.

References TauImpactParameterInfo().

31 { return new TauImpactParameterInfo( * this ); }
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().

8  {
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) ip = ipData->ip3D;
18 
19  if( ip.value() < ip_min ||
20  ip.value() > ip_max ||
21  ip.significance() < sip_min ){
22  discriminator = 0;
23  }
24  }
25  return discriminator;
26 }
bool isNull() const
Checks for null.
Definition: Ref.h:249
double significance() const
Definition: Measurement1D.h:32
IsolatedTauTagInfoRef isolatedTaus
const TauImpactParameterTrackData * getTrackData(const reco::TrackRef &) const
double value() const
Definition: Measurement1D.h:28
float reco::TauImpactParameterInfo::discriminator ( ) const

Definition at line 27 of file TauImpactParameterInfo.cc.

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

Definition at line 52 of file TauImpactParameterInfo.cc.

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

Definition at line 32 of file TauImpactParameterInfo.cc.

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

32  {
33 
35  = trackDataMap.find(trackRef);
36 
37  if (iter != trackDataMap.end()) return &(iter->val);
38 
39  return 0; // if track not found return 0
40 }
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 48 of file TauImpactParameterInfo.cc.

Referenced by ImpactParameterAlgorithm::tag().

48  {
49  isolatedTaus = isolationRef;
50 }
IsolatedTauTagInfoRef isolatedTaus
void reco::TauImpactParameterInfo::storeTrackData ( const reco::TrackRef trackRef,
const TauImpactParameterTrackData trackData 
)

Definition at line 42 of file TauImpactParameterInfo.cc.

Referenced by ImpactParameterAlgorithm::tag().

43  {
44 
45  trackDataMap.insert(trackRef, trackData);
46 }
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 44 of file TauImpactParameterInfo.h.

TrackTauImpactParameterAssociationCollection reco::TauImpactParameterInfo::trackDataMap
private

Definition at line 43 of file TauImpactParameterInfo.h.