Go to the documentation of this file.
7 #ifndef CBM_TRD_ELECTRONS_TRAIN_ANN
8 #define CBM_TRD_ELECTRONS_TRAIN_ANN
12 #include "TMVA/Factory.h"
13 #include "TMVA/Reader.h"
14 #include "TMultiLayerPerceptron.h"
45 TrdEloss(
double eloss,
double dedx = 0.,
double tr = 0.)
69 virtual InitStatus
Init();
74 virtual void Exec(Option_t* opt);
84 void Draw(Option_t* =
"");
141 Double_t
Eval(Bool_t isEl);
184 std::vector<std::vector<std::vector<TrdEloss>>>
fEloss;
221 TMultiLayerPerceptron*
fNN;
233 std::vector<std::vector<TH1*>>
TrdEloss(double eloss, double dedx=0., double tr=0.)
void SetNofTrainSamples(Int_t nofTr)
void SetBeamDataFile(std::string beamDataFile)
void FillElossVectorSim()
Fill vector with energy loss information for simulated data.
CbmTrdElectronsTrainAnn(const CbmTrdElectronsTrainAnn &)
Double_t FindOptimalCut()
std::vector< Float_t > fAnnInput
void FillElossVectorReal()
Fill vector with energy loss information simulated from real data spectra.
std::vector< TH1 * > fhCumProbOutput
virtual void Finish()
Inherited from FairTask.
std::vector< TH1 * > fhEloss
TMultiLayerPerceptron * fNN
void SetOutputDir(const std::string &outputDir)
void CreateCumProbOutputHist()
TGraph * CreateRocDiagramm()
virtual InitStatus Init()
Inherited from FairTask.
virtual ~CbmTrdElectronsTrainAnn()
Destructor.
TClonesArray * fTrdTrackMatches
TMVA::Factory * CreateFactory(TTree *simu)
std::vector< std::vector< TH1 * > > fhInput
std::string fBeamDataPiHist
std::vector< std::vector< TH1 * > > fhElossSort
void SetIsDoTrain(Bool_t doTrain)
std::string CreateAnnString()
void SetNofAnnEpochs(Int_t nofAnnEpochs)
void Draw(Option_t *="")
Draw results.
ClassDef(CbmTrdElectronsTrainAnn, 1)
void SetIdMethod(IdMethod idMethod)
std::vector< TH1 * > fHists
void FillAnnInputHist(Bool_t isEl)
std::string fBeamDataElHist
void SetBeamDataPiHist(std::string beamDataPiHist)
virtual void Exec(Option_t *opt)
Inherited from FairTask.
TMVA::Reader * CreateTmvaReader()
std::vector< TH1 * > fhMeanEloss
Represents information about energy losses in one layer.
std::string fBeamDataFile
TClonesArray * fTrdPoints
TClonesArray * fTrdTracks
void SetSigmaError(Double_t sigma)
void SetTransformType(Int_t type)
CbmTrdElectronsTrainAnn(int nofTrdLayers)
Default constructor.
std::vector< TH1 * > fhOutput
CbmTrdElectronsTrainAnn & operator=(const CbmTrdElectronsTrainAnn &)
void SetBeamDataElHist(std::string beamDataElHist)
std::vector< std::vector< std::vector< TrdEloss > > > fEloss
Double_t Eval(Bool_t isEl)
void SortElossAndFillHist()
Sort energy losses and fill histograms.
void FillElossHist()
Fill histograms with energy loss information.