Project
Loading...
Searching...
No Matches
ClustererParam.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 ALICEO2_ITSMFTCLUSTERERPARAM_H_
16#define ALICEO2_ITSMFTCLUSTERERPARAM_H_
17
21#include <string_view>
22#include <string>
23
24namespace o2
25{
26namespace itsmft
27{
28template <int N>
29struct ClustererParam : public o2::conf::ConfigurableParamHelper<ClustererParam<N>> {
30 static_assert(N == o2::detectors::DetID::ITS || N == o2::detectors::DetID::MFT, "only DetID::ITS or DetID:: MFT are allowed");
31
32 static constexpr int getNLayers()
33 {
34 return N == o2::detectors::DetID::ITS ? 7 : 10;
35 }
36
37 static constexpr std::string_view getParamName()
38 {
39 return N == o2::detectors::DetID::ITS ? ParamName[0] : ParamName[1];
40 }
41
42 int maxRowColDiffToMask = DEFRowColDiffToMask();
45 float maxSOTMUS = 8.;
46 bool dropHugeClusters = false;
52
54
55 private:
56 static constexpr int DEFRowColDiffToMask()
57 {
58 // default neighbourhood definition
59 return N == o2::detectors::DetID::ITS ? 1 : 1; // ITS and MFT will suppress also closest neighbours
60 }
61
62 static constexpr std::string_view ParamName[2] = {"ITSClustererParam", "MFTClustererParam"};
63};
64
65template <int N>
66ClustererParam<N> ClustererParam<N>::sInstance;
67
68} // namespace itsmft
69
70namespace framework
71{
72template <typename T>
73struct is_messageable;
74template <>
75struct is_messageable<o2::itsmft::ClustererParam<o2::detectors::DetID::ITS>> : std::true_type {
76};
77template <typename T>
78struct is_messageable;
79template <>
80struct is_messageable<o2::itsmft::ClustererParam<o2::detectors::DetID::MFT>> : std::true_type {
81};
82} // namespace framework
83
84} // namespace o2
85
86#endif
static constexpr ID ITS
Definition DetID.h:63
static constexpr ID MFT
Definition DetID.h:71
GLboolean * data
Definition glcorearb.h:298
GLenum GLuint GLint GLint layer
Definition glcorearb.h:1310
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...
int maxBCDiffToSquashBiasLayer[getNLayers()]
squash mask per layer
float maxSOTMUS
max expected signal over threshold in \mus
int getMaxBCDiffToSquashBias(int layer) const noexcept
static constexpr int getNLayers()
int maxBCDiffToSquashBias
squash if 2 ROFs differ by <= StrobeLength + Bias BCs, use value <0 to disable squashing
static constexpr std::string_view getParamName()
int maxRowColDiffToMask
pixel may be masked as overflow if such a neighbour in prev frame was fired
int maxBCDiffToMaskBias
mask if 2 ROFs differ by <= StrobeLength + Bias BCs, use value <0 to disable masking
O2ParamDef(ClustererParam, getParamName().data())
bool dropHugeClusters
option to drop huge clusters (mitigate beam background)