Project
Loading...
Searching...
No Matches
CompressedClusters.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
15
16#ifndef ALICEO2_DATAFORMATSTPC_COMPRESSED_CLUSTERS_H
17#define ALICEO2_DATAFORMATSTPC_COMPRESSED_CLUSTERS_H
18
19#include "GPUCommonDef.h"
20#include "GPUCommonRtypes.h"
21
22namespace o2
23{
24namespace tpc
25{
27 unsigned int nTracks = 0;
28 unsigned int nAttachedClusters = 0;
29 unsigned int nUnattachedClusters = 0;
30 unsigned int nAttachedClustersReduced = 0;
31 unsigned int nSliceRows = 36 * 152;
32 unsigned char nComppressionModes = 0; // Don't fix this name due to ROOT dictionaries!
33 float solenoidBz = -1e6f;
34 int maxTimeBin = -1e6;
35
37};
38
39template <class TCHAR, class TSHORT, class TINT>
41 TSHORT qTotA = 0;
42 TSHORT qMaxA = 0;
43 TCHAR flagsA = 0;
44 TCHAR rowDiffA = 0;
45 TCHAR sliceLegDiffA = 0;
46 TSHORT padResA = 0;
47 TINT timeResA = 0;
48 TCHAR sigmaPadA = 0;
49 TCHAR sigmaTimeA = 0;
50
51 TCHAR qPtA = 0;
52 TCHAR rowA = 0;
53 TCHAR sliceA = 0;
54 TINT timeA = 0;
55 TSHORT padA = 0;
56
57 TSHORT qTotU = 0;
58 TSHORT qMaxU = 0;
59 TCHAR flagsU = 0;
60 TSHORT padDiffU = 0;
61 TINT timeDiffU = 0;
62 TCHAR sigmaPadU = 0;
63 TCHAR sigmaTimeU = 0;
64
65 TSHORT nTrackClusters = 0;
67
69};
70
71struct CompressedClustersPtrs : public CompressedClustersPtrs_x<unsigned char*, unsigned short*, unsigned int*> {
72};
73
74struct CompressedClustersOffsets : public CompressedClustersPtrs_x<size_t, size_t, size_t> {
75};
76
78
79struct CompressedClusters : public CompressedClustersCounters, public CompressedClustersPtrs { // TODO: Need a const version of this, currently the constructor allows to create a non-const version from const CompressedClustersFlat, which should not be allowed
80 CompressedClusters() = default;
83
84 void dump();
85
87};
88
99
101 friend struct CompressedClusters; // We don't want anyone to access the members directly, should only be used to construct a CompressedClusters struct
102 CompressedClustersFlat() = delete; // Must not be constructed
103 size_t totalDataSize = 0; // Total data size of header + content
104 const CompressedClusters* ptrForward = nullptr; // Must be 0 if this object is really flat, or can be a ptr to a CompressedClusters struct (abusing the flat structure to forward a ptr to the e.g. root version)
105
106 void set(size_t bufferSize, const CompressedClusters& v);
107 void setForward(const CompressedClusters* p);
108};
109
110} // namespace tpc
111} // namespace o2
112
113#endif
uint32_t c
Definition RawData.h:2
const GLdouble * v
Definition glcorearb.h:832
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...
ClassDefNV(CompressedClustersCounters, 3)
void setForward(const CompressedClusters *p)
const CompressedClusters * ptrForward
void set(size_t bufferSize, const CompressedClusters &v)
ClassDefNV(CompressedClustersPtrs_x, 3)
ClassDefNV(CompressedClustersROOT, 3)
CompressedClustersROOT(const CompressedClusters &v)
CompressedClustersROOT(const CompressedClustersFlat &v)
ClassDefNV(CompressedClusters, 3)