Project
Loading...
Searching...
No Matches
FullCluster.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#include <gsl/gsl>
13#ifndef ALICEO2_CPV_FULLCLUSTER_H_
14#define ALICEO2_CPV_FULLCLUSTER_H_
15
19
20namespace o2
21{
22namespace cpv
23{
26
27class FullCluster : public Cluster
28{
29
30 using Label = o2::MCCompLabel;
31
32 public:
33 struct CluElement {
34 short absId;
35 float energy;
36 float localX;
37 float localZ;
38 int label;
39 CluElement(short a, float e, float x, float z, int l) : absId(a), energy(e), localX(x), localZ(z), label(l) {}
40 };
41
42 FullCluster() = default;
43 FullCluster(short digitAbsId, float energy, int label);
44
45 ~FullCluster() = default;
46
49 void addDigit(short digitAbsId, float energy, int label);
50
51 void evalAll();
52
53 // Get index of a digit with i
54 short getDigitAbsId(Int_t i) const { return mElementList.at(i).absId; }
55
56 const std::vector<CluElement>* getElementList() const { return &mElementList; }
57
58 // Counts local maxima and returns their positions
59 char getNumberOfLocalMax(gsl::span<int> maxAt) const;
60
61 void purify(); // Removes digits below threshold
62
63 protected:
64 void evalLocalPosition(); // computes the position in the CPV module
65
66 private:
67 std::vector<CluElement> mElementList;
68
69 ClassDefNV(FullCluster, 1);
70};
71} // namespace cpv
72} // namespace o2
73
74#endif
int32_t i
Contains CPV cluster parameters.
Definition Cluster.h:33
CPV cluster implementation.
Definition FullCluster.h:28
char getNumberOfLocalMax(gsl::span< int > maxAt) const
const std::vector< CluElement > * getElementList() const
Definition FullCluster.h:56
void addDigit(short digitAbsId, float energy, int label)
Method to add digit to a cluster.
short getDigitAbsId(Int_t i) const
Definition FullCluster.h:54
GLint GLenum GLint x
Definition glcorearb.h:403
GLuint GLsizei const GLchar * label
Definition glcorearb.h:2519
GLboolean GLboolean GLboolean GLboolean a
Definition glcorearb.h:1233
GLdouble GLdouble GLdouble z
Definition glcorearb.h:843
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...
CluElement(short a, float e, float x, float z, int l)
Definition FullCluster.h:39