Project
Loading...
Searching...
No Matches
GPUReconstructionTimeframe.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 GPURECONSTRUCTIONTIMEFRAME_H
16#define GPURECONSTRUCTIONTIMEFRAME_H
17
18#include "GPUChainTracking.h"
19#include "GPUDataTypes.h"
20#include "GPUTPCGeometry.h"
21#include <vector>
22#include <random>
23#include <tuple>
24
25namespace o2::tpc
26{
27struct ClusterNative;
28} // namespace o2::tpc
29
30namespace o2::gpu
31{
32struct ClusterNativeAccess;
33
35{
36 public:
37 GPUReconstructionTimeframe(GPUChainTracking* rec, int32_t (*read)(int32_t), int32_t nEvents);
38 int32_t LoadCreateTimeFrame(int32_t iEvent);
39 int32_t LoadMergedEvents(int32_t iEvent);
40 int32_t ReadEventShifted(int32_t i, float shiftZ, float minZ = -1e6, float maxZ = -1e6, bool silent = false);
41 void MergeShiftedEvents();
42
43 static constexpr int32_t ORBIT_RATE = 11245;
44 static constexpr int32_t DRIFT_TIME = 93000;
45 static constexpr int32_t TPCZ = GPUTPCGeometry::TPCLength();
46 static constexpr int32_t TIME_ORBIT = 1000000000 / ORBIT_RATE;
47
48 private:
49 constexpr static uint32_t NSECTORS = GPUReconstruction::NSECTORS;
50
51 void SetDisplayInformation(int32_t iCol);
52
53 GPUChainTracking* mChain;
54 int32_t (*mReadEvent)(int32_t);
55 int32_t mNEventsInDirectory;
56
57 std::uniform_real_distribution<double> mDisUniReal;
58 std::uniform_int_distribution<uint64_t> mDisUniInt;
59 std::mt19937_64 mRndGen1;
60 std::mt19937_64 mRndGen2;
61
62 int32_t mTrainDist = 0;
63 float mCollisionProbability = 0.f;
64 int32_t mMaxBunchesFull;
65 int32_t mMaxBunches;
66
67 int32_t mNTotalCollisions = 0;
68
69 int64_t mEventStride;
70 int32_t mSimBunchNoRepeatEvent;
71 std::vector<int8_t> mEventUsed;
72 std::vector<std::tuple<GPUTrackingInOutPointers, GPUChainTracking::InOutMemory, o2::tpc::ClusterNativeAccess>> mShiftedEvents;
73};
74} // namespace o2::gpu
75
76#endif
int32_t i
int32_t ReadEventShifted(int32_t i, float shiftZ, float minZ=-1e6, float maxZ=-1e6, bool silent=false)
static constexpr uint32_t NSECTORS
GLfloat GLfloat GLfloat GLfloat GLfloat GLfloat maxZ
Definition glcorearb.h:2910
GLfloat GLfloat minZ
Definition glcorearb.h:2910
Global TPC definitions and constants.
Definition SimTraits.h:167
GPUReconstruction * rec
const int nEvents
Definition test_Fifo.cxx:27