Project
Loading...
Searching...
No Matches
PreClusterizer.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
16
17#ifndef O2_MID_PRECLUSTERIZER_H
18#define O2_MID_PRECLUSTERIZER_H
19
20#include <unordered_map>
21#include <unordered_set>
22#include <vector>
23#include <gsl/gsl>
24#include "MIDBase/Mapping.h"
28
29namespace o2
30{
31namespace mid
32{
35{
36 public:
40 void process(gsl::span<const ColumnData> stripPatterns, bool accumulate = false);
41
45 void process(gsl::span<const ColumnData> stripPatterns, gsl::span<const ROFRecord> rofRecords);
46
48 const std::vector<PreCluster>& getPreClusters() { return mPreClusters; }
49
51 const std::vector<ROFRecord>& getROFRecords() { return mROFRecords; }
52
53 private:
54 struct PatternStruct {
55 uint8_t deId = 0;
56 int firedColumns = 0;
57 std::array<ColumnData, 7> columns;
58 };
59
63 bool loadPatterns(gsl::span<const ColumnData>& stripPatterns);
64
67 void preClusterizeBP(PatternStruct& de);
68
71 void preClusterizeNBP(PatternStruct& de);
72
73 Mapping mMapping;
74 std::unordered_map<uint8_t, PatternStruct> mMpDEs;
75 std::unordered_set<uint8_t> mActiveDEs;
76 std::vector<PreCluster> mPreClusters;
77 std::vector<ROFRecord> mROFRecords;
78};
79} // namespace mid
80} // namespace o2
81
82#endif /* O2_MID_PRECLUSTERIZER_H */
Strip pattern (aka digits)
Timeframe settings Average distance in cm of events merged into Randomize distance around average distance of merged events Simulate correct bunch interactions instead of placing only the average number of events A value[n] sets TFlen for[n] collisions in Number of bunches per trainsort Number of bunch trains Instantaneous interaction rate Do not simulate border Total number of collisions to be placed in the interior of all time Do not select random but walk over array of events in stride steps h Event generator settings h configStandalone Use CPU for GPU Force usage of the specified GPU device no CPU fallback Continue processing after an error First event to process
Pre-cluster structure for MID.
Mapping for MID.
Definition of the MID event record.
Checks validity of hardware address (HW) and transform it to digit AbsId index.
Pre-clustering algorithm for MID.
const std::vector< ROFRecord > & getROFRecords()
Gets the vector of pre-clusters RO frame records.
const std::vector< PreCluster > & getPreClusters()
Gets the vector of reconstructed pre-clusters.
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...
uint16_t de