Project
Loading...
Searching...
No Matches
CellLabel.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 ALICEO2_EMCAL_CELLLABEL_H_
13#define ALICEO2_EMCAL_CELLLABEL_H_
14
15#include <fairlogger/Logger.h>
16#include <gsl/span>
17#include <vector>
18#include "Rtypes.h"
19
20namespace o2
21{
22
23namespace emcal
24{
25
32
34{
35 public:
36 // CellLabel() = default;
37
41 CellLabel(const gsl::span<const int> labels, const gsl::span<const float> amplitudeFractions);
42
43 // ~CellLabel() = default;
44 // CellLabel(const CellLabel& clus) = default;
45 // CellLabel& operator=(const CellLabel& source) = default;
46
49 size_t GetLabelSize(void) const { return mLabels.size(); }
50
53 int32_t GetLabel(size_t index) const { return mLabels[index]; }
54
57 float GetAmplitudeFraction(size_t index) const { return mAmplitudeFraction[index]; }
58
59 protected:
60 gsl::span<const int32_t> mLabels;
61 gsl::span<const float> mAmplitudeFraction;
62};
63
64} // namespace emcal
65} // namespace o2
66#endif // ALICEO2_EMCAL_CELLLABEL_H_
cell class for MC particle IDs and their respective amplitude fraction
Definition CellLabel.h:34
int32_t GetLabel(size_t index) const
Getter for label.
Definition CellLabel.h:53
float GetAmplitudeFraction(size_t index) const
Getter for amplitude fraction.
Definition CellLabel.h:57
size_t GetLabelSize(void) const
Getter of label size.
Definition CellLabel.h:49
gsl::span< const int32_t > mLabels
List of MC particles that generated the cluster, ordered in deposited energy.
Definition CellLabel.h:60
gsl::span< const float > mAmplitudeFraction
List of the fraction of the cell energy coming from a MC particle. Index aligns with mLabels!
Definition CellLabel.h:61
GLuint index
Definition glcorearb.h:781
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...