Belle II Software development
eclNOptimalCollectorModule.h
1/**************************************************************************
2 * basf2 (Belle II Analysis Software Framework) *
3 * Author: The Belle II Collaboration *
4 * *
5 * See git log for contributors and copyright holders. *
6 * This file is licensed under LGPL-3.0, see LICENSE.md. *
7 **************************************************************************/
8
9#pragma once
10
11/* ECL headers. */
12#include <ecl/dataobjects/ECLElementNumbers.h>
13
14/* Basf2 headers. */
15#include <calibration/CalibrationCollectorModule.h>
16#include <framework/datastore/StoreArray.h>
17
18namespace Belle2 {
23 class ECLCluster;
24 class ECLShower;
25 class ECLCalDigit;
26 class MCParticle;
27
28 namespace ECL {
29 class ECLNeighbours;
30 }
31
42
43 public:
44
47
49 void prepare() override;
50
52 void collect() override;
53
54 private:
55
58 std::vector<double> m_energiesForward;
59 std::vector<double> m_energiesBarrel;
60 std::vector<double> m_energiesBackward;
62 std::string m_digitArrayName;
63 std::string m_showerArrayName;
68 std::vector< std::vector<int> > iEnergies;
69 const int iFirstCellId = 161;
70 const int iLastCellId = 8608;
71 const int nLeakReg = 3;
72 const int nCrysMax = 21;
78 std::vector<int> thetaIDofCrysID;
80 bool storeParameters = true;
87 };
89}
Calibration collector module base class.
Class to get the neighbours for a given cell id.
Definition: ECLNeighbours.h:25
Accessor to arrays stored in the data store.
Definition: StoreArray.h:113
Collector that runs on single photon MC samples to find the number of crystals to be summed to get th...
StoreArray< MCParticle > m_mcParticleArray
Array of MCParticles.
StoreArray< ECLShower > m_eclShowerArray
Required arrays.
const int iFirstCellId
first useful cellID (first of thetaID 3)
int m_nGroupPerThetaID
number of groups per standard thetaID
std::vector< std::vector< int > > iEnergies
Some other useful quantities.
std::vector< double > m_energiesBarrel
generated photon energies, barrel
const int iLastCellId
first useful cellID (last of thetaID 66)
const int nCrysMax
max number of crystals used to calculate energy
int nCrystalGroups
sort the crystals into this many groups
const int nLeakReg
0 = forward, 1 = barrel, 2 = backward
StoreArray< ECLCluster > m_eclClusterArray
Array of ECLClusters.
int iGroupOfCrystal[ECLElementNumbers::c_NCrystals]
group number of each crystal
ECL::ECLNeighbours * neighbours
neighbours to crystal
std::vector< int > thetaIDofCrysID
thetaID of each crystal
void collect() override
Select events and crystals and accumulate histograms.
eclNOptimalCollectorModule()
Constructor: Sets the description, the properties and the parameters of the module.
std::string m_showerArrayName
Name of ECLShower StoreArray.
std::string m_digitArrayName
Name of ECLCalDigit StoreArray.
StoreArray< ECLCalDigit > m_eclCalDigitArray
Array of ECLCalDigits.
void prepare() override
Define histograms.
std::vector< double > m_energiesForward
generated photon energies, forward
bool storeParameters
store parameters first event
std::vector< double > m_energiesBackward
generated photon energies, backward
const int c_NCrystals
Number of crystals.
Abstract base class for different kinds of events.