BOSS 7.0.5
BESIII Offline Software System
Loading...
Searching...
No Matches
TofQPID Class Reference

#include <TofQPID.h>

+ Inheritance diagram for TofQPID:

Public Member Functions

 ~TofQPID ()
 
void init ()
 
void calculate ()
 
bool IsPidInfoValid () const
 
double chi (int n) const
 
double prob (int n) const
 
int ndof () const
 
double hitstatus () const
 
int neuronPID () const
 
 ~TofQPID ()
 
void init ()
 
void calculate ()
 
bool IsPidInfoValid () const
 
double chi (int n) const
 
double prob (int n) const
 
int ndof () const
 
double hitstatus () const
 
int neuronPID () const
 
- Public Member Functions inherited from ParticleIDBase
 ParticleIDBase ()
 
virtual ~ParticleIDBase ()
 
virtual void init ()=0
 
virtual void calculate ()=0
 
virtual bool IsPidInfoValid () const =0
 
virtual double chi (int n) const =0
 
virtual double prob (int n) const =0
 
virtual int ndof () const =0
 
EvtRecTrackPidTrk () const
 
void setRecTrack (EvtRecTrack *trk)
 
double chiMinCut () const
 
void setChiMinCut (const double chi=4)
 
double chiMaxCut () const
 
void setChiMaxCut (const double chi=6)
 
double pdfMinSigmaCut () const
 
void setPdfMinSigmaCut (const double pdf=4)
 
double getRunNo () const
 
void setRunNo (const double runh=8093)
 
double p ()
 
double pt ()
 
double charge ()
 
double xmass (int n)
 
double velc ()
 
double probCalculate (double chi2, int n)
 
double pdfCalculate (double offset, double sigma)
 
double interpolation (double *x, double *y, double x1)
 
double pol2 (double x, double *par)
 
double pol3 (double x, double *par)
 
double pol4 (double x, double *par)
 
int useDedx () const
 
int useTof () const
 
int useTof1 () const
 
int useTof2 () const
 
int useTofE () const
 
int useTofQ () const
 
int useTofC () const
 
int useTofCorr () const
 
int useEmc () const
 
int useMuc () const
 
int onlyPionKaon () const
 
int onlyPionKaonProton () const
 
int onlyPionKaonElectron () const
 
int all () const
 
int onlyElectron () const
 
int onlyMuon () const
 
int onlyPion () const
 
int onlyKaon () const
 
int onlyProton () const
 
int methodLikelihood () const
 
int methodProbability () const
 
int methodNeuronNetwork () const
 
int dedxValid () const
 
int tofValid () const
 
int tofeValid () const
 
int tofqValid () const
 
int tofcValid () const
 
int tofcorrValid () const
 
int emcValid () const
 
int mucValid () const
 
void set_path (const char *s_path=0)
 
void set_path (std::string s_path)
 
 ParticleIDBase ()
 
virtual ~ParticleIDBase ()
 
virtual void init ()=0
 
virtual void calculate ()=0
 
virtual bool IsPidInfoValid () const =0
 
virtual double chi (int n) const =0
 
virtual double prob (int n) const =0
 
virtual int ndof () const =0
 
EvtRecTrackPidTrk () const
 
void setRecTrack (EvtRecTrack *trk)
 
double chiMinCut () const
 
void setChiMinCut (const double chi=4)
 
double chiMaxCut () const
 
void setChiMaxCut (const double chi=6)
 
double pdfMinSigmaCut () const
 
void setPdfMinSigmaCut (const double pdf=4)
 
double getRunNo () const
 
void setRunNo (const double runh=8093)
 
double p ()
 
double pt ()
 
double charge ()
 
double xmass (int n)
 
double velc ()
 
double probCalculate (double chi2, int n)
 
double pdfCalculate (double offset, double sigma)
 
double interpolation (double *x, double *y, double x1)
 
double pol2 (double x, double *par)
 
double pol3 (double x, double *par)
 
double pol4 (double x, double *par)
 
int useDedx () const
 
int useTof () const
 
int useTof1 () const
 
int useTof2 () const
 
int useTofE () const
 
int useTofQ () const
 
int useTofC () const
 
int useTofCorr () const
 
int useEmc () const
 
int useMuc () const
 
int onlyPionKaon () const
 
int onlyPionKaonProton () const
 
int onlyPionKaonElectron () const
 
int all () const
 
int onlyElectron () const
 
int onlyMuon () const
 
int onlyPion () const
 
int onlyKaon () const
 
int onlyProton () const
 
int methodLikelihood () const
 
int methodProbability () const
 
int methodNeuronNetwork () const
 
int dedxValid () const
 
int tofValid () const
 
int tofeValid () const
 
int tofqValid () const
 
int tofcValid () const
 
int tofcorrValid () const
 
int emcValid () const
 
int mucValid () const
 
void set_path (const char *s_path=0)
 
void set_path (std::string s_path)
 

Static Public Member Functions

static TofQPIDinstance ()
 
static TofQPIDinstance ()
 

Protected Member Functions

int neuronPIDCalculation ()
 
int particleIDCalculation ()
 
int LikelihoodCalculation ()
 
int neuronPIDCalculation ()
 
int particleIDCalculation ()
 
int LikelihoodCalculation ()
 
virtual int particleIDCalculation ()=0
 
virtual int LikelihoodCalculation ()=0
 
virtual int particleIDCalculation ()=0
 
virtual int LikelihoodCalculation ()=0
 

Additional Inherited Members

- Static Protected Attributes inherited from ParticleIDBase
static std::string path = ""
 

Detailed Description

Constructor & Destructor Documentation

◆ ~TofQPID() [1/2]

TofQPID::~TofQPID ( )
inline

◆ ~TofQPID() [2/2]

TofQPID::~TofQPID ( )
inline

Definition at line 17 of file InstallArea/include/ParticleID/ParticleID/TofQPID.h.

17{;}

Member Function Documentation

◆ calculate() [1/2]

void TofQPID::calculate ( )
virtual

Implements ParticleIDBase.

Definition at line 34 of file TofQPID.cxx.

34 {
35 if(particleIDCalculation() == 0) m_ndof=1;
36}
int particleIDCalculation()
Definition: TofQPID.cxx:37

◆ calculate() [2/2]

void TofQPID::calculate ( )
virtual

Implements ParticleIDBase.

◆ chi() [1/2]

double TofQPID::chi ( int  n) const
inlinevirtual

Implements ParticleIDBase.

Definition at line 22 of file Analysis/ParticleID/ParticleID-00-04-68/ParticleID/TofQPID.h.

22{return m_chi[n];}
const Int_t n

◆ chi() [2/2]

double TofQPID::chi ( int  n) const
inlinevirtual

Implements ParticleIDBase.

Definition at line 22 of file InstallArea/include/ParticleID/ParticleID/TofQPID.h.

22{return m_chi[n];}

◆ hitstatus() [1/2]

double TofQPID::hitstatus ( ) const
inline

Definition at line 25 of file Analysis/ParticleID/ParticleID-00-04-68/ParticleID/TofQPID.h.

25{return m_hitstatus;}

◆ hitstatus() [2/2]

double TofQPID::hitstatus ( ) const
inline

Definition at line 25 of file InstallArea/include/ParticleID/ParticleID/TofQPID.h.

25{return m_hitstatus;}

◆ init() [1/2]

void TofQPID::init ( )
virtual

Implements ParticleIDBase.

Definition at line 22 of file TofQPID.cxx.

22 {
23 for(int i = 0; i < 5; i++) {
24 m_chi[i] = 99.0;
25 m_prob[i] = -1.0;
26 }
27 m_chimin = 99.;
28 m_ndof = 0;
29 m_hitstatus = -2;
30 // m_q1 = -1;
31 // m_q2 = -1;
32}

◆ init() [2/2]

void TofQPID::init ( )
virtual

Implements ParticleIDBase.

◆ instance() [1/2]

TofQPID * TofQPID::instance ( )
static

Definition at line 13 of file TofQPID.cxx.

13 {
14 if(!m_pointer) m_pointer = new TofQPID();
15 return m_pointer;
16}

◆ instance() [2/2]

static TofQPID * TofQPID::instance ( )
static

◆ IsPidInfoValid() [1/2]

bool TofQPID::IsPidInfoValid ( ) const
inlinevirtual

Implements ParticleIDBase.

Definition at line 21 of file Analysis/ParticleID/ParticleID-00-04-68/ParticleID/TofQPID.h.

21{return (m_ndof > 0);}

◆ IsPidInfoValid() [2/2]

bool TofQPID::IsPidInfoValid ( ) const
inlinevirtual

Implements ParticleIDBase.

Definition at line 21 of file InstallArea/include/ParticleID/ParticleID/TofQPID.h.

21{return (m_ndof > 0);}

◆ LikelihoodCalculation() [1/2]

int TofQPID::LikelihoodCalculation ( )
inlineprotectedvirtual

Implements ParticleIDBase.

Definition at line 34 of file Analysis/ParticleID/ParticleID-00-04-68/ParticleID/TofQPID.h.

34{return -1;}

◆ LikelihoodCalculation() [2/2]

int TofQPID::LikelihoodCalculation ( )
inlineprotectedvirtual

Implements ParticleIDBase.

Definition at line 34 of file InstallArea/include/ParticleID/ParticleID/TofQPID.h.

34{return -1;}

◆ ndof() [1/2]

int TofQPID::ndof ( ) const
inlinevirtual

Implements ParticleIDBase.

Definition at line 24 of file Analysis/ParticleID/ParticleID-00-04-68/ParticleID/TofQPID.h.

24{return m_ndof;}

◆ ndof() [2/2]

int TofQPID::ndof ( ) const
inlinevirtual

Implements ParticleIDBase.

Definition at line 24 of file InstallArea/include/ParticleID/ParticleID/TofQPID.h.

24{return m_ndof;}

◆ neuronPID() [1/2]

int TofQPID::neuronPID ( ) const
inline

Definition at line 28 of file Analysis/ParticleID/ParticleID-00-04-68/ParticleID/TofQPID.h.

28{return -1;}

◆ neuronPID() [2/2]

int TofQPID::neuronPID ( ) const
inline

Definition at line 28 of file InstallArea/include/ParticleID/ParticleID/TofQPID.h.

28{return -1;}

◆ neuronPIDCalculation() [1/2]

int TofQPID::neuronPIDCalculation ( )
inlineprotected

Definition at line 32 of file Analysis/ParticleID/ParticleID-00-04-68/ParticleID/TofQPID.h.

32{ return -1;}

◆ neuronPIDCalculation() [2/2]

int TofQPID::neuronPIDCalculation ( )
inlineprotected

Definition at line 32 of file InstallArea/include/ParticleID/ParticleID/TofQPID.h.

32{ return -1;}

◆ particleIDCalculation() [1/2]

int TofQPID::particleIDCalculation ( )
protectedvirtual

Implements ParticleIDBase.

Definition at line 37 of file TofQPID.cxx.

37 {
38 int irc = -1;
39 EvtRecTrack* recTrk = PidTrk();
40 if(!(recTrk->isMdcTrackValid())) return irc;
41 // RecMdcTrack* mdcTrk = recTrk->mdcTrack();
42
43 // double ptrk = mdcTrk->p();
44 // double cost = cos(mdcTrk->theta());
45
46 if(!(recTrk->isTofTrackValid())) return irc;
47 // RecTofTrack* tofTrk = recTrk->tofTrack();
48
49 //
50 // two layer hit in barrel TOF are required
51 //
52 // if(tofTrk->getPart() != 1) return irc;
53 // double ph1 = tofTrk->getPh1();
54 // double ph2 = tofTrk->getPh2();
55 // if(ph1 <= 0 || ph2 <= 0) return irc;
56 //
57 // Tof Q calibration is needed
58 //
59 // m_hitstatus = tofTrk->getHitStatus();
60 //m_hitstatus = 1;
61 //if(m_hitstatus == 0 || m_hitstatus == 1) m_q1 = tofTrk->getQ1();
62 //if(m_hitstatus == 0 || m_hitstatus == 2) m_q2 = tofTrk->getQ2();
63
64 //m_q1 = 1.0;
65 //m_q2 = 1.0;
66 m_ndof = 1;
67 irc = 0;
68 return irc;
69}

Referenced by calculate().

◆ particleIDCalculation() [2/2]

int TofQPID::particleIDCalculation ( )
protectedvirtual

Implements ParticleIDBase.

◆ prob() [1/2]

double TofQPID::prob ( int  n) const
inlinevirtual

Implements ParticleIDBase.

Definition at line 23 of file Analysis/ParticleID/ParticleID-00-04-68/ParticleID/TofQPID.h.

23{return m_prob[n];}

◆ prob() [2/2]

double TofQPID::prob ( int  n) const
inlinevirtual

Implements ParticleIDBase.

Definition at line 23 of file InstallArea/include/ParticleID/ParticleID/TofQPID.h.

23{return m_prob[n];}

The documentation for this class was generated from the following files: