27 LOGP(warn,
"No OpenMP");
37 const auto& vidx = mSectors[sec].rows[
row];
38 const auto* clarr = tpcClusterIdxStruct.
clusters[sec][
row];
40 int ncl = vidx.size(),
left = 0,
right = ncl;
43 if (clarr[vidx[mid]].
getTime() < tbmin) {
52 int idmin =
left, idmax =
left, idtst = idmin;
54 while (++idtst < ncl && clarr[vidx[idtst]].
getTime() <= tbmax) {
57 return {idmin, idmax};
63 const auto& vidx = mSectors[sec].rows[
row];
64 const auto* clarr = tpcClusterIdxStruct.
clusters[sec][
row];
66 int ncl = vidx.size(),
left = 0,
right = ncl;
72 if (clarr[vidx[mid]].
getTime() < tbmin) {
83 const auto& cl = clarr[vidx[
left]];
84 if (cl.getTime() > tbmax) {
87 if (cl.getPad() >= padmin && cl.getPad() <= padmax) {
90 clIDDirect->push_back(vidx[
left]);
99 for (
int is = 0; is < NSectors; is++) {
100 auto& sect = mSectors[is];
102#pragma omp parallel for schedule(dynamic) num_threads(mNThreads)
104 for (
int ir = 0;
ir < Sector::NRows;
ir++) {
105 size_t ncl = tpcClusterIdxStruct.
nClusters[is][
ir];
107 LOGP(error,
"Row {} of sector {} has {} clusters, truncating to {}",
ir, is, ncl,
int(0xffff));
110 auto& rowidx = sect.rows[
ir];
112 std::iota(rowidx.begin(), rowidx.end(), 0);
113 const auto* clus = tpcClusterIdxStruct.
clusters[is][
ir];
114 std::sort(rowidx.begin(), rowidx.end(), [&](
size_t a,
size_t b) { return clus[a].getTime() < clus[b].getTime(); });
Helper class to read the binary format of TPC ClusterNative.
std::pair< int, int > findClustersRange(int sec, int row, float tbmin, float tbmax, const o2::tpc::ClusterNativeAccess &tpcClusterIdxStruct)
void fill(const o2::tpc::ClusterNativeAccess &tpcClusterIdxStruct)
int findClustersEntries(int sec, int row, float tbmin, float tbmax, float padmin, float padmax, const o2::tpc::ClusterNativeAccess &tpcClusterIdxStruct, std::vector< int > *clIDDirect=nullptr)
GLboolean GLboolean GLboolean b
GLboolean GLboolean GLboolean GLboolean a
Global TPC definitions and constants.
std::string getTime(uint64_t ts)
unsigned int nClusters[constants::MAXSECTOR][constants::MAXGLOBALPADROW]
const ClusterNative * clusters[constants::MAXSECTOR][constants::MAXGLOBALPADROW]
o2::InteractionRecord ir(0, 0)