Project
Loading...
Searching...
No Matches
EMCALDigitizerSpec.h
Go to the documentation of this file.
1// Copyright 2019-2020 CERN and copyright holders of ALICE O2.
2// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
3// All rights not expressly granted are reserved.
4//
5// This software is distributed under the terms of the GNU General Public
6// License v3 (GPL Version 3), copied verbatim in the file "COPYING".
7//
8// In applying this license CERN does not waive the privileges and immunities
9// granted to it by virtue of its status as an Intergovernmental Organization
10// or submit itself to any jurisdiction.
11
12#ifndef STEER_DIGITIZERWORKFLOW_EMCALDIGITIZER_H_
13#define STEER_DIGITIZERWORKFLOW_EMCALDIGITIZER_H_
14
15#include <memory>
16#include <vector>
17
19#include "Framework/Task.h"
21#include "EMCALBase/Hit.h"
27
28class TChain;
29
30namespace o2
31{
32
33namespace steer
34{
35class MCKinematicsReader;
36}
37
38namespace ctp
39{
40class CTPConfiguration;
41}
42
43namespace emcal
44{
45class CalibLoader;
46
49
56{
57 public:
60 DigitizerSpec(std::shared_ptr<CalibLoader> calibloader, bool requireCTPInput) : o2::base::BaseDPLDigitizer(o2::base::InitServices::GEOM), o2::framework::Task(), mRequireCTPInput(requireCTPInput), mCalibHandler(calibloader) {}
61
63 ~DigitizerSpec() final = default;
64
67 void initDigitizerTask(framework::InitContext& ctx) final;
68
69 void finaliseCCDB(o2::framework::ConcreteDataMatcher& matcher, void* obj) final;
70
71 void configure();
72
80 void run(framework::ProcessingContext& ctx) override;
81
82 private:
83 Bool_t mFinished = false;
84 bool mIsConfigured = false;
85 bool mRunSDitizer = false;
86 bool mRequireCTPInput = false;
87 Digitizer mDigitizer;
88 o2::emcal::SDigitizer mSumDigitizer;
89 std::shared_ptr<CalibLoader> mCalibHandler;
90 std::vector<Hit> mHits;
91 std::vector<TChain*> mSimChains;
92 o2::ctp::CTPConfiguration* mCTPConfig;
93 o2::steer::MCKinematicsReader* mcReader;
94
95 DigitizerTRU mDigitizerTRU;
96 o2::emcal::SDigitizer mSumDigitizerTRU;
97 bool mRunDigitizerTRU = true;
98};
99
102o2::framework::DataProcessorSpec getEMCALDigitizerSpec(int channel, bool requireCTPInput, bool mctruth = true, bool useccdb = true);
103
104} // namespace emcal
105} // end namespace o2
106
107#endif /* STEER_DIGITIZERWORKFLOW_EMCALDIGITIZER_H_ */
Definition of the base digitizer task class.
Definition of a container to keep Monte Carlo truth external to simulation objects.
virtual void init(o2::framework::InitContext &) final
Handler for EMCAL calibration objects in DPL workflows.
Definition CalibLoader.h:50
Create new digitizer spec.
void run(framework::ProcessingContext &ctx) override
run digitizer
void initDigitizerTask(framework::InitContext &ctx) final
init digitizer
void finaliseCCDB(o2::framework::ConcreteDataMatcher &matcher, void *obj) final
DigitizerSpec(std::shared_ptr< CalibLoader > calibloader, bool requireCTPInput)
Constructor.
~DigitizerSpec() final=default
Destructor.
EMCAL DigitizerTRU, digitizes with the help of a temporary description based upon a pol9*Heavyside.
EMCAL FEE digitizer.
Definition Digitizer.h:51
EMCAL simulation hit information.
Definition Hit.h:28
EMCAL summed digitizer.
Definition SDigitizer.h:43
o2::framework::DataProcessorSpec getEMCALDigitizerSpec(int channel, bool requireCTPInput, bool mctruth=true, bool useccdb=true)
Create new digitizer spec.
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...
Defining DataPointCompositeObject explicitly as copiable.