AliPhysics  b752f14 (b752f14)
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
AliEmcalCorrectionCellCombineCollections Class Reference

Combines two cell collections into one collection. More...

#include <AliEmcalCorrectionCellCombineCollections.h>

Inheritance diagram for AliEmcalCorrectionCellCombineCollections:

Public Member Functions

 AliEmcalCorrectionCellCombineCollections ()
 
virtual ~AliEmcalCorrectionCellCombineCollections ()
 
Bool_t Initialize ()
 
void UserCreateOutputObjects ()
 
void ExecOnce ()
 
Bool_t Run ()
 
std::string GetExternalCellsBranchName () const
 
std::string GetCombinedCellsBranchName () const
 
void SetExternalCellsBranchName (const char *inputName)
 
void SetCombinedCellsBranchName (const char *inputName)
 
- Public Member Functions inherited from AliEmcalCorrectionComponent
 AliEmcalCorrectionComponent ()
 
 AliEmcalCorrectionComponent (const char *name)
 
virtual ~AliEmcalCorrectionComponent ()
 
virtual Bool_t UserNotify ()
 
virtual Bool_t CheckIfRunChanged ()
 
void GetEtaPhiDiff (const AliVTrack *t, const AliVCluster *v, Double_t &phidiff, Double_t &etadiff)
 
void UpdateCells ()
 
void GetPass ()
 
void FillCellQA (TH1F *h)
 
Int_t InitBadChannels ()
 
AliParticleContainerAddParticleContainer (const char *n)
 
AliTrackContainerAddTrackContainer (const char *n)
 
AliMCParticleContainerAddMCParticleContainer (const char *n)
 
AliClusterContainerAddClusterContainer (const char *n)
 
void AdoptParticleContainer (AliParticleContainer *cont)
 
void AdoptTrackContainer (AliTrackContainer *cont)
 
void AdoptMCParticleContainer (AliMCParticleContainer *cont)
 
void AdoptClusterContainer (AliClusterContainer *cont)
 
AliParticleContainerGetParticleContainer (Int_t i=0) const
 
AliParticleContainerGetParticleContainer (const char *name) const
 
AliClusterContainerGetClusterContainer (Int_t i=0) const
 
AliClusterContainerGetClusterContainer (const char *name) const
 
AliMCParticleContainerGetMCParticleContainer (Int_t i=0) const
 
AliMCParticleContainerGetMCParticleContainer (const char *name) const
 
AliTrackContainerGetTrackContainer (Int_t i=0) const
 
AliTrackContainerGetTrackContainer (const char *name) const
 
void RemoveParticleContainer (Int_t i=0)
 
void RemoveClusterContainer (Int_t i=0)
 
AliVCaloCells * GetCaloCells () const
 
TListGetOutputList () const
 
void SetCaloCells (AliVCaloCells *cells)
 
void SetRecoUtils (AliEMCALRecoUtils *ru)
 
void SetEvent (AliVEvent *event)
 
void SetMCEvent (AliMCEvent *mcevent)
 
void SetEMCALGeometry (AliEMCALGeometry *geometry)
 
void SetCentralityBin (Int_t bin)
 
void SetCentrality (Double_t cent)
 
void SetNcentralityBins (Int_t n)
 
void SetIsESD (Bool_t isESD)
 
void SetUserConfiguration (YAML::Node &node)
 Make copy to ensure that the nodes do not point to each other (?) More...
 
void SetDefaultConfiguration (YAML::Node &node)
 
template<typename T >
bool GetProperty (std::string propertyName, T &property, bool requiredProperty=true, std::string correctionName="")
 Retrieve property. More...
 

Protected Member Functions

void SetupCombinedCells ()
 
void CreateCombinedCells ()
 
void AddCellsToCombinedCellObject (AliVCaloCells *inputCells)
 
void AddObjectToEvent (TObject *obj, AliVEvent *event, Bool_t attempt=kFALSE)
 
 AliEmcalCorrectionCellCombineCollections (const AliEmcalCorrectionCellCombineCollections &)
 
AliEmcalCorrectionCellCombineCollectionsoperator= (const AliEmcalCorrectionCellCombineCollections &)
 

Protected Attributes

std::string fExternalCellsBranchName
 Name of the cell branch which will be copied from the external event for the combined cells. More...
 
std::string fCreatedCellsBranchName
 Name of the cell branch which will be created for the combined cells. More...
 
bool fInitializedCombinedCells
 ! True if the combined cells object has been initialized More...
 
AliVCaloCells * fCombinedCells
 ! Cells combined from the input and external events. More...
 
- Protected Attributes inherited from AliEmcalCorrectionComponent
YAML::Node fUserConfiguration
 ! User YAML configuration More...
 
YAML::Node fDefaultConfiguration
 ! Default YAML configuration More...
 
Bool_t fCreateHisto
 Flag to make some basic histograms. More...
 
Int_t fRun
 ! Run number More...
 
TString fFilepass
 Input data pass number. More...
 
Bool_t fGetPassFromFileName
 Get fFilepass from file name. More...
 
AliVEvent * fEvent
 ! Pointer to event More...
 
Bool_t fEsdMode
 flag for ESD More...
 
AliMCEvent * fMCEvent
 ! MC More...
 
Double_t fCent
 ! Event centrality More...
 
Int_t fNcentBins
 How many centrality bins (this member copied from AliAnalysisTaskEmcal) More...
 
Int_t fCentBin
 ! Event centrality bin More...
 
Int_t fNbins
 No. of pt bins. More...
 
Double_t fMinBinPt
 Min pt in histograms. More...
 
Double_t fMaxBinPt
 Max pt in histograms. More...
 
Double_t fVertex [3]
 ! Event vertex More...
 
AliEMCALGeometry * fGeom
 ! Geometry object More...
 
Bool_t fIsEmbedded
 Trigger, embedded signal. More...
 
Int_t fMinMCLabel
 Minimum MC label value for the tracks/clusters being considered MC particles. More...
 
TObjArray fClusterCollArray
 Cluster collection array. More...
 
TObjArray fParticleCollArray
 Particle/track collection array. More...
 
AliVCaloCells * fCaloCells
 ! Pointer to CaloCells More...
 
AliEMCALRecoUtils * fRecoUtils
 Pointer to RecoUtils. More...
 
TListfOutput
 ! List of output histograms More...
 
TString fBasePath
 Base folder path to get root files. More...
 

Static Protected Attributes

static
RegisterCorrectionComponent
< AliEmcalCorrectionCellCombineCollections
reg
 

Additional Inherited Members

- Static Public Member Functions inherited from AliEmcalCorrectionComponent
template<typename T >
static bool GetProperty (std::string propertyName, T &property, const YAML::Node &userConfiguration, const YAML::Node &defaultConfiguration, bool requiredProperty=true, std::string correctionName="")
 Retrieve property driver function. It is static so that it can be used by other classes. More...
 
static bool IsSharedValue (std::string &value)
 
- Static Protected Member Functions inherited from AliEmcalCorrectionComponent
template<typename T >
static bool GetPropertyFromNodes (const YAML::Node &node, const YAML::Node &sharedParametersNode, std::string propertyName, T &property, const std::string correctionName, const std::string configurationType, int nodesDeep=0)
 
template<typename T >
static bool GetPropertyFromNode (const YAML::Node &node, std::string propertyName, T &property)
 
template<typename T >
static std::enable_if
<!std::is_arithmetic< T >
::value &&!std::is_same< T,
std::string >::value
&&!std::is_same< T, bool >
::value >::type 
PrintRetrievedPropertyValue (T &property, std::stringstream &tempMessage)
 
template<typename T >
static std::enable_if
< std::is_arithmetic< T >
::value||std::is_same< T,
std::string >::value||std::is_same
< T, bool >::value >::type 
PrintRetrievedPropertyValue (T &property, std::stringstream &tempMessage)
 

Detailed Description

Combines two cell collections into one collection.

The internal cell branch should be set by the correction task! Then, the external cell branch name should be set in the correction configuration. The branch will be retrieved by this task.

Note that this task must run in a seperate correction task and must be configured to run after the previous ones. Otherwise, the cell branches will not yet be corrected!

With a bit of generalization, along with some small modifications in AliEmcalCorrectionTask, this task could combine aribtrary collections of cells together. However, this is quite unnecessary for the current purposes, so it will be left for the future if it is necessary.

Author
Raymond Ehlers raymo.nosp@m.nd.e.nosp@m.hlers.nosp@m.@yal.nosp@m.e.edu, Yale University, centralize EMCal corrections using components
Date
Dec 6, 2016

Definition at line 30 of file AliEmcalCorrectionCellCombineCollections.h.

Constructor & Destructor Documentation

AliEmcalCorrectionCellCombineCollections::AliEmcalCorrectionCellCombineCollections ( )

Standard constructor for the correction components.

Definition at line 24 of file AliEmcalCorrectionCellCombineCollections.cxx.

AliEmcalCorrectionCellCombineCollections::~AliEmcalCorrectionCellCombineCollections ( )
virtual

Destructor.

Definition at line 38 of file AliEmcalCorrectionCellCombineCollections.cxx.

AliEmcalCorrectionCellCombineCollections::AliEmcalCorrectionCellCombineCollections ( const AliEmcalCorrectionCellCombineCollections )
protected

Member Function Documentation

void AliEmcalCorrectionCellCombineCollections::AddCellsToCombinedCellObject ( AliVCaloCells *  inputCells)
protected

Takes the input cells and adds them to the combine cells. To do so, the each individual cell must be duplicated.

Parameters
[in]inputCellsCells to be added to the combined cells

Definition at line 173 of file AliEmcalCorrectionCellCombineCollections.cxx.

Referenced by CreateCombinedCells().

void AliEmcalCorrectionCellCombineCollections::AddObjectToEvent ( TObject obj,
AliVEvent *  event,
Bool_t  attempt = kFALSE 
)
protected

Add object to event. Adapted from AliAnalysisTaskEmcal.

Parameters
[in]objObject to be added
[in]eventEvent to which the object is added
[in]attemptIf true don't handle error

Definition at line 205 of file AliEmcalCorrectionCellCombineCollections.cxx.

Referenced by SetupCombinedCells().

void AliEmcalCorrectionCellCombineCollections::CreateCombinedCells ( )
protected

Create cells combined from the input event and the external (embedded) event. This is only necessary for cells because they basic object is a cell "container" rather than the actual objects, which can then be accessed through EMCal containers (like clusters or tracks).

Definition at line 138 of file AliEmcalCorrectionCellCombineCollections.cxx.

Referenced by Run().

void AliEmcalCorrectionCellCombineCollections::ExecOnce ( )
virtual

The combined cells are setup during ExecOnce() to atempt to make the cell object creation as efficient as possible (although it is difficult to do compared to AliEmcalContainer derived classes).

Reimplemented from AliEmcalCorrectionComponent.

Definition at line 86 of file AliEmcalCorrectionCellCombineCollections.cxx.

std::string AliEmcalCorrectionCellCombineCollections::GetCombinedCellsBranchName ( ) const
inline

Definition at line 42 of file AliEmcalCorrectionCellCombineCollections.h.

std::string AliEmcalCorrectionCellCombineCollections::GetExternalCellsBranchName ( ) const
inline

Definition at line 41 of file AliEmcalCorrectionCellCombineCollections.h.

Bool_t AliEmcalCorrectionCellCombineCollections::Initialize ( )
virtual

Initialize all needed variables from the YAML configuration.

Note that "usedefault" is only applied to the externalCellsBranchName because the "usedefault" name for the combinedCellsBranchName is not well defined. However, just using the default in the default YAML configuration should serve more or less the same purpose.

Reimplemented from AliEmcalCorrectionComponent.

Definition at line 52 of file AliEmcalCorrectionCellCombineCollections.cxx.

AliEmcalCorrectionCellCombineCollections& AliEmcalCorrectionCellCombineCollections::operator= ( const AliEmcalCorrectionCellCombineCollections )
protected
Bool_t AliEmcalCorrectionCellCombineCollections::Run ( )
virtual

Run each event to fill the combined cells from input and external cells. Note that the combined cells object should have already been created.

Reimplemented from AliEmcalCorrectionComponent.

Definition at line 122 of file AliEmcalCorrectionCellCombineCollections.cxx.

void AliEmcalCorrectionCellCombineCollections::SetCombinedCellsBranchName ( const char *  inputName)
inline

Definition at line 45 of file AliEmcalCorrectionCellCombineCollections.h.

void AliEmcalCorrectionCellCombineCollections::SetExternalCellsBranchName ( const char *  inputName)
inline

Definition at line 44 of file AliEmcalCorrectionCellCombineCollections.h.

void AliEmcalCorrectionCellCombineCollections::SetupCombinedCells ( )
protected

Setup the combined cells object and add it to the input event.

NOTE: It could have been added to the embedded event, but then classes outside of AliEmcalCorrection{Task,Component} have some difficulty in using them. It is better to put them in the input event, although it is important to ensure that the requested name is not already in use.

Definition at line 99 of file AliEmcalCorrectionCellCombineCollections.cxx.

Referenced by CreateCombinedCells(), and ExecOnce().

void AliEmcalCorrectionCellCombineCollections::UserCreateOutputObjects ( )
virtual

Create user output objects.

Reimplemented from AliEmcalCorrectionComponent.

Definition at line 75 of file AliEmcalCorrectionCellCombineCollections.cxx.

Member Data Documentation

AliVCaloCells* AliEmcalCorrectionCellCombineCollections::fCombinedCells
protected

! Cells combined from the input and external events.

Definition at line 57 of file AliEmcalCorrectionCellCombineCollections.h.

Referenced by AddCellsToCombinedCellObject(), CreateCombinedCells(), and SetupCombinedCells().

std::string AliEmcalCorrectionCellCombineCollections::fCreatedCellsBranchName
protected

Name of the cell branch which will be created for the combined cells.

Definition at line 55 of file AliEmcalCorrectionCellCombineCollections.h.

Referenced by GetCombinedCellsBranchName(), Initialize(), SetCombinedCellsBranchName(), and SetupCombinedCells().

std::string AliEmcalCorrectionCellCombineCollections::fExternalCellsBranchName
protected

Name of the cell branch which will be copied from the external event for the combined cells.

Definition at line 54 of file AliEmcalCorrectionCellCombineCollections.h.

Referenced by CreateCombinedCells(), GetExternalCellsBranchName(), Initialize(), and SetExternalCellsBranchName().

bool AliEmcalCorrectionCellCombineCollections::fInitializedCombinedCells
protected

! True if the combined cells object has been initialized

Definition at line 56 of file AliEmcalCorrectionCellCombineCollections.h.

Referenced by CreateCombinedCells(), and SetupCombinedCells().

RegisterCorrectionComponent< AliEmcalCorrectionCellCombineCollections > AliEmcalCorrectionCellCombineCollections::reg
staticprotected

Definition at line 63 of file AliEmcalCorrectionCellCombineCollections.h.


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