k4SimGeant4
Loading...
Searching...
No Matches
SamplingFractionInLayers Class Reference

Histograms of energy deposited in active material and total energy deposited in the calorimeter. More...

#include <Detector/DetStudies/src/components/SamplingFractionInLayers.h>

Inheritance diagram for SamplingFractionInLayers:
Collaboration diagram for SamplingFractionInLayers:

Public Member Functions

 SamplingFractionInLayers (const std::string &, ISvcLocator *)
 
virtual ~SamplingFractionInLayers ()
 
virtual StatusCode initialize () final
 Initialize.
 
virtual StatusCode execute (const EventContext &) const final
 Fills the histograms.
 
virtual StatusCode finalize () final
 Finalize.
 

Private Attributes

ServiceHandle< ITHistSvc > m_histSvc
 Pointer to the interface of histogram service.
 
ServiceHandle< IGeoSvc > m_geoSvc
 Pointer to the geometry service.
 
DataHandle< edm4hep::SimCalorimeterHitCollection > m_deposits {"rec/caloHits", Gaudi::DataHandle::Reader, this}
 Handle for the energy deposits.
 
Gaudi::Property< std::string > m_activeFieldName {this, "activeFieldName", "", "Identifier of active material"}
 Name of the active field.
 
Gaudi::Property< int > m_activeFieldValue {this, "activeFieldValue", 0, "Value of identifier for active material"}
 Value of the active material.
 
Gaudi::Property< std::string > m_layerFieldName {this, "layerFieldName", "", "Identifier of layers"}
 Name of the layer/cell field.
 
Gaudi::Property< uint > m_numLayers {this, "numLayers", 8, "Number of layers"}
 Number of layers/cells.
 
Gaudi::Property< uint > m_firstLayerId {this, "firstLayerId", 0, "ID of first layer"}
 Id of the first layer.
 
Gaudi::Property< std::string > m_readoutName {this, "readoutName", "", "Name of the detector readout"}
 Name of the detector readout.
 
Gaudi::Property< double > m_energy {this, "energyAxis", 500, "Maximum energy for axis range"}
 
std::vector< TH1F * > m_totalEnLayers
 
TH1F * m_totalEnergy
 
std::vector< TH1F * > m_activeEnLayers
 
TH1F * m_totalActiveEnergy
 
std::vector< TH1F * > m_sfLayers
 
TH1F * m_sf
 

Detailed Description

Histograms of energy deposited in active material and total energy deposited in the calorimeter.

Passive material needs to be marked as sensitive. It needs to be divided into layers (cells) as active material. Sampling fraction is calculated for each layer as the ratio of energy deposited in active material to energy deposited in the layer (also in passive material).

Author
Anna Zaborowska

Constructor & Destructor Documentation

◆ SamplingFractionInLayers()

SamplingFractionInLayers::SamplingFractionInLayers ( const std::string & aName,
ISvcLocator * aSvcLoc )
explicit

◆ ~SamplingFractionInLayers()

SamplingFractionInLayers::~SamplingFractionInLayers ( )
virtual

Member Function Documentation

◆ execute()

StatusCode SamplingFractionInLayers::execute ( const EventContext & ) const
finalvirtual

Fills the histograms.

Returns
status code

◆ finalize()

StatusCode SamplingFractionInLayers::finalize ( )
finalvirtual

Finalize.

Returns
status code

◆ initialize()

StatusCode SamplingFractionInLayers::initialize ( )
finalvirtual

Initialize.

Returns
status code

Member Data Documentation

◆ m_activeEnLayers

std::vector<TH1F*> SamplingFractionInLayers::m_activeEnLayers
private

◆ m_activeFieldName

Gaudi::Property<std::string> SamplingFractionInLayers::m_activeFieldName {this, "activeFieldName", "", "Identifier of active material"}
private

Name of the active field.

◆ m_activeFieldValue

Gaudi::Property<int> SamplingFractionInLayers::m_activeFieldValue {this, "activeFieldValue", 0, "Value of identifier for active material"}
private

Value of the active material.

◆ m_deposits

DataHandle<edm4hep::SimCalorimeterHitCollection> SamplingFractionInLayers::m_deposits {"rec/caloHits", Gaudi::DataHandle::Reader, this}
mutableprivate

Handle for the energy deposits.

◆ m_energy

Gaudi::Property<double> SamplingFractionInLayers::m_energy {this, "energyAxis", 500, "Maximum energy for axis range"}
private

◆ m_firstLayerId

Gaudi::Property<uint> SamplingFractionInLayers::m_firstLayerId {this, "firstLayerId", 0, "ID of first layer"}
private

Id of the first layer.

◆ m_geoSvc

ServiceHandle<IGeoSvc> SamplingFractionInLayers::m_geoSvc
private

Pointer to the geometry service.

◆ m_histSvc

ServiceHandle<ITHistSvc> SamplingFractionInLayers::m_histSvc
private

Pointer to the interface of histogram service.

◆ m_layerFieldName

Gaudi::Property<std::string> SamplingFractionInLayers::m_layerFieldName {this, "layerFieldName", "", "Identifier of layers"}
private

Name of the layer/cell field.

◆ m_numLayers

Gaudi::Property<uint> SamplingFractionInLayers::m_numLayers {this, "numLayers", 8, "Number of layers"}
private

Number of layers/cells.

◆ m_readoutName

Gaudi::Property<std::string> SamplingFractionInLayers::m_readoutName {this, "readoutName", "", "Name of the detector readout"}
private

Name of the detector readout.

◆ m_sf

TH1F* SamplingFractionInLayers::m_sf
private

◆ m_sfLayers

std::vector<TH1F*> SamplingFractionInLayers::m_sfLayers
private

◆ m_totalActiveEnergy

TH1F* SamplingFractionInLayers::m_totalActiveEnergy
private

◆ m_totalEnergy

TH1F* SamplingFractionInLayers::m_totalEnergy
private

◆ m_totalEnLayers

std::vector<TH1F*> SamplingFractionInLayers::m_totalEnLayers
private

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