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 Member Functions | Private Attributes
MaterialBudgetHistos Class Reference

#include <MaterialBudgetHistos.h>

Inheritance diagram for MaterialBudgetHistos:
MaterialBudgetFormat

Public Member Functions

void endOfRun () override
 
void fillEndTrack () override
 
void fillPerStep () override
 
void fillStartTrack () override
 
 MaterialBudgetHistos (std::shared_ptr< MaterialBudgetData > data, std::shared_ptr< TestHistoMgr > mgr, const std::string &fileName)
 
 ~MaterialBudgetHistos () override
 
- Public Member Functions inherited from MaterialBudgetFormat
 MaterialBudgetFormat (std::shared_ptr< MaterialBudgetData > data)
 
virtual ~MaterialBudgetFormat ()
 

Private Member Functions

virtual void book ()
 

Private Attributes

std::shared_ptr< TestHistoMgrhmgr
 
double * theDmb
 
double * theMateId
 
double * theVoluId
 
double * theX
 
double * theY
 
double * theZ
 

Additional Inherited Members

- Protected Attributes inherited from MaterialBudgetFormat
std::shared_ptr
< MaterialBudgetData
theData
 
std::string theFileName
 

Detailed Description

Definition at line 7 of file MaterialBudgetHistos.h.

Constructor & Destructor Documentation

MaterialBudgetHistos::MaterialBudgetHistos ( std::shared_ptr< MaterialBudgetData data,
std::shared_ptr< TestHistoMgr mgr,
const std::string &  fileName 
)

Definition at line 4 of file MaterialBudgetHistos.cc.

References book(), MillePedeFileConverter_cfg::fileName, and MaterialBudgetFormat::theFileName.

9  book();
10 }
MaterialBudgetFormat(std::shared_ptr< MaterialBudgetData > data)
char data[epos_bytes_allocation]
Definition: EPOS_Wrapper.h:79
std::shared_ptr< TestHistoMgr > hmgr
MaterialBudgetHistos::~MaterialBudgetHistos ( )
inlineoverride

Definition at line 12 of file MaterialBudgetHistos.h.

12 {}

Member Function Documentation

void MaterialBudgetHistos::book ( )
privatevirtual

Definition at line 12 of file MaterialBudgetHistos.cc.

References hmgr.

Referenced by MaterialBudgetHistos().

12  {
13  edm::LogInfo("MaterialBudget") << " MaterialBudgetHistos: Booking Histos";
14  hmgr->addHistoProf1(new TProfile("10", "MB prof Eta ", 250, -5., 5.));
15  hmgr->addHisto1(new TH1F("11", "Eta ", 501, -5., 5.));
16  hmgr->addHistoProf1(new TProfile("20", "MB prof Phi ", 180, -3.1416, 3.1416));
17  hmgr->addHisto1(new TH1F("21", "Phi ", 360, -3.1416, 3.1416));
18  hmgr->addHistoProf2(new TProfile2D("30", "MB prof Eta Phi ", 250, -5., 5., 180, -3.1416, 3.1416));
19  hmgr->addHisto2(new TH2F("31", "Eta vs Phi ", 501, -5., 5., 180, -3.1416, 3.1416));
20 }
Log< level::Info, false > LogInfo
std::shared_ptr< TestHistoMgr > hmgr
void MaterialBudgetHistos::endOfRun ( )
overridevirtual

Reimplemented from MaterialBudgetFormat.

Definition at line 36 of file MaterialBudgetHistos.cc.

References hmgr, and MaterialBudgetFormat::theFileName.

36  {
37  edm::LogInfo("MaterialBudget") << "MaterialBudgetHistos: Writing Histos ROOT file to" << theFileName;
38  hmgr->save(theFileName);
39 }
Log< level::Info, false > LogInfo
std::shared_ptr< TestHistoMgr > hmgr
void MaterialBudgetHistos::fillEndTrack ( )
overridevirtual

Reimplemented from MaterialBudgetFormat.

Definition at line 26 of file MaterialBudgetHistos.cc.

References hmgr, and MaterialBudgetFormat::theData.

26  {
27  hmgr->getHisto1(11)->Fill(theData->getEta());
28  hmgr->getHisto1(21)->Fill(theData->getPhi());
29  hmgr->getHisto2(31)->Fill(theData->getEta(), theData->getPhi());
30 
31  hmgr->getHistoProf1(10)->Fill(theData->getEta(), theData->getTotalMB());
32  hmgr->getHistoProf1(20)->Fill(theData->getPhi(), theData->getTotalMB());
33  hmgr->getHistoProf2(30)->Fill(theData->getEta(), theData->getPhi(), theData->getTotalMB());
34 }
std::shared_ptr< TestHistoMgr > hmgr
std::shared_ptr< MaterialBudgetData > theData
void MaterialBudgetHistos::fillPerStep ( )
overridevirtual

Reimplemented from MaterialBudgetFormat.

Definition at line 24 of file MaterialBudgetHistos.cc.

24 {}
void MaterialBudgetHistos::fillStartTrack ( )
overridevirtual

Reimplemented from MaterialBudgetFormat.

Definition at line 22 of file MaterialBudgetHistos.cc.

22 {}

Member Data Documentation

std::shared_ptr<TestHistoMgr> MaterialBudgetHistos::hmgr
private

Definition at line 29 of file MaterialBudgetHistos.h.

Referenced by book(), endOfRun(), and fillEndTrack().

double* MaterialBudgetHistos::theDmb
private

Definition at line 22 of file MaterialBudgetHistos.h.

double* MaterialBudgetHistos::theMateId
private

Definition at line 27 of file MaterialBudgetHistos.h.

double* MaterialBudgetHistos::theVoluId
private

Definition at line 26 of file MaterialBudgetHistos.h.

double* MaterialBudgetHistos::theX
private

Definition at line 23 of file MaterialBudgetHistos.h.

double* MaterialBudgetHistos::theY
private

Definition at line 24 of file MaterialBudgetHistos.h.

double* MaterialBudgetHistos::theZ
private

Definition at line 25 of file MaterialBudgetHistos.h.