Project
Loading...
Searching...
No Matches
EntropyDecoderSpec.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
14
15#ifndef O2_ITSMFT_ENTROPYDECODER_SPEC
16#define O2_ITSMFT_ENTROPYDECODER_SPEC
17
19#include "Framework/Task.h"
20#include "Headers/DataHeader.h"
24#include <TStopwatch.h>
25#include <memory>
26
27namespace o2
28{
29namespace itsmft
30{
31
33{
34 public:
35 EntropyDecoderSpec(o2::header::DataOrigin orig, int verbosity, bool getDigits = false);
36 ~EntropyDecoderSpec() override = default;
37 void init(o2::framework::InitContext& ic) final;
40 void finaliseCCDB(o2::framework::ConcreteDataMatcher& matcher, void* obj) final;
41
42 static auto getName(o2::header::DataOrigin orig) { return std::string{orig == o2::header::gDataOriginITS ? ITSDeviceName : MFTDeviceName}; }
43
44 private:
45 void updateTimeDependentParams(o2::framework::ProcessingContext& pc);
46
47 static constexpr std::string_view ITSDeviceName = "its-entropy-decoder";
48 static constexpr std::string_view MFTDeviceName = "mft-entropy-decoder";
50 o2::itsmft::CTFCoder mCTFCoder;
51 const NoiseMap* mNoiseMap = nullptr;
52 LookUp mPattIdConverter;
53 bool mGetDigits{false};
54 bool mMaskNoise{false};
55 bool mUseClusterDictionary{true};
56 std::string mDetPrefix{};
57
58 std::string mCTFDictPath{};
59 TStopwatch mTimer;
60};
61
63framework::DataProcessorSpec getEntropyDecoderSpec(o2::header::DataOrigin orig, int verbosity, bool getDigits, unsigned int sspec);
64
65} // namespace itsmft
66} // namespace o2
67
68#endif
#define verbosity
class for entropy encoding/decoding of ITS/MFT compressed clusters data
Definition of the LookUp class.
Definition of the ITSMFT NoiseMap.
void finaliseCCDB(o2::framework::ConcreteDataMatcher &matcher, void *obj) final
~EntropyDecoderSpec() override=default
void endOfStream(o2::framework::EndOfStreamContext &ec) final
This is invoked whenever we have an EndOfStream event.
static auto getName(o2::header::DataOrigin orig)
void run(o2::framework::ProcessingContext &pc) final
void init(o2::framework::InitContext &ic) final
NoiseMap class for the ITS and MFT.
Definition NoiseMap.h:39
constexpr o2::header::DataOrigin gDataOriginInvalid
Definition DataHeader.h:561
constexpr o2::header::DataOrigin gDataOriginITS
Definition DataHeader.h:570
framework::DataProcessorSpec getEntropyDecoderSpec(o2::header::DataOrigin orig, int verbosity, bool getDigits, unsigned int sspec)
create a processor spec
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...