|
CbmRoot
|
#include <Hitfinder.h>
Public Member Functions | |
| XPU_D void | SortDigisInSpaceAndTime (SortDigis::context &) const |
| XPU_D void | FindClustersSingleStep (FindClusters::context &) const |
| XPU_D void | SortClusters (SortClusters::context &) const |
| XPU_D void | FindHits (FindHits::context &) const |
| XPU_D void | CalculateOffsetsParallel (FindClusters::context &) const |
| XPU_D void | FindClustersParallel (FindClusters::context &) const |
| XPU_D void | CalculateClustersParallel (FindClusters::context &) const |
Private Member Functions | |
| XPU_D void | CalculateChannelOffsets (FindClusters::context &ctx, CbmStsDigi *digis, unsigned int *channelOffsets, unsigned int nDigis) const |
| XPU_D void | FindClusterConnectionsDigiWise (FindClusters::context &ctx, CbmStsDigi *digis, DigiConnector *digiConnector, unsigned int *channelOffsets, unsigned int nDigis) const |
| XPU_D void | CalculateClustersDigiWise (FindClusters::context &ctx, CbmStsDigi *digis, DigiConnector *digiConnector, unsigned int const nDigis) const |
| XPU_D void | CreateClusterFromConnectors1 (int const iModule, const CbmStsDigi *digis, int const digiIndex) const |
| XPU_D void | CreateClusterFromConnectors2 (int const iModule, const CbmStsDigi *digis, DigiConnector *digiConnector, int const digiIndex) const |
| XPU_D void | CreateClusterFromConnectorsN (int const iModule, const CbmStsDigi *digis, DigiConnector *digiConnector, int const digiIndex) const |
| XPU_D unsigned int | GetNDigis (int iModule) const |
| XPU_D float | GetTimeResolution (int, int) const |
| XPU_D bool | IsActive (int *channelStatus, int channel) const |
| XPU_D int | ChanLeft (int channel) const |
| XPU_D int | ChanRight (int channel) const |
| XPU_D int | ChanDist (int c1, int c2) const |
| XPU_D void | AddCluster (int iModule, uint32_t time, const sts::Cluster &cls) const |
| XPU_D bool | IsBackside (int iModule) const |
| XPU_D float | LandauWidth (float charge) const |
| XPU_D void | ToGlobal (int iModule, float lx, float ly, float lz, float &gx, float &gy, float &gz) const |
| XPU_D void | IntersectClusters (int iBlock, const HitfinderCache &pars, const ClusterIdx &idxF, const sts::Cluster &clsF, const ClusterIdx &idxB, const sts::Cluster &clsB) const |
| XPU_D float | GetClusterPosition (const HitfinderCache &pars, float centre, bool isFront) const |
| XPU_D bool | Intersect (const HitfinderCache &pars, float xF, float exF, float xB, float exB, float &x, float &y, float &varX, float &varY, float &varXY) const |
| XPU_D bool | IsInside (const HitfinderCache &pars, float x, float y) const |
| XPU_D void | CreateHit (int iBlocks, float xLocal, float yLocal, float varX, float varY, float varXY, const ClusterIdx &idxF, const Cluster &clsF, const ClusterIdx &idxB, const sts::Cluster &clsB, float du, float dv) const |
| XPU_D float | GetTimeDiff (const CbmStsDigi &d1, const CbmStsDigi &d2) const |
| XPU_D float | GetTimeDiff (const ClusterIdx &d1, const ClusterIdx &d2) const |
| XPU_D void | SaveMaxError (float errorValue, int iModule) const |
Definition at line 198 of file Hitfinder.h.
|
inlineprivate |
Definition at line 357 of file Hitfinder.h.
References clusterDataPerModule, clusterIdxPerModule, maxClustersPerModule, monitor, nClustersPerModule, and pos.
Referenced by CreateClusterFromConnectors1(), CreateClusterFromConnectors2(), and CreateClusterFromConnectorsN().
|
private |
sts::Hitfinder::calculateChannelOffsets Calculates the Offsest of every channel. digis-Array is sorted in Channel and Time. If a channelChange is detected it is stored in channelOffsetsPerModule.
| digis | All Digis that are relevant for this Block |
| channelOffsets | The Array where all offsets are written to |
| nDigis | Amount of digis in digis-Array |
Definition at line 92 of file Hitfinder.cxx.
References CbmStsDigi::GetChannel(), nChannels, and pos.
Referenced by CalculateOffsetsParallel().
|
private |
sts::Hitfinder::calculateClustersDigiWise
Each Thread one Channel
ChannelId: 00000 11111 DigiIndex: 01234 56789 ThreadId: 01234 56789
Calculates the Clustercharges of all found ClusterConnections. Each Thread takes on digi and looks for connections. When the thread is done, it takes the next digi. If one Digi does not have a previous one it's a cluster start and may be the start of either a single-element-cluster, double-element-cluster or multi-element-cluster.
| digis | All Digis that are relevant for this Block |
| digiConnector | Array where the connection between 2 digis is sotred in.(next Digi; has Previous) |
| iModule | The Module that the curren Block is working on |
| threadId | Id of the thrad currently working |
Definition at line 282 of file Hitfinder.cxx.
| XPU_D void sts::Hitfinder::CalculateClustersParallel | ( | FindClusters::context & | ctx | ) | const |
sts::Hitfinder::calculateClustersParallel This function calculates clusters form an sts-Digi Array inserted. It runs the calculating process highly parallel.
| iBlock | is the Block/Module that is currently worked on |
Definition at line 218 of file Hitfinder.cxx.
References CreateClusterFromConnectors1(), CreateClusterFromConnectors2(), CreateClusterFromConnectorsN(), digiConnectorsPerModule, digiOffsetPerModule, digisPerModule, GetNDigis(), and nModules.
Referenced by FindClustersSingleStep().
| XPU_D void sts::Hitfinder::CalculateOffsetsParallel | ( | FindClusters::context & | ctx | ) | const |
sts::Hitfinder::calculateOffsetsParallel This function calculates the channeloffsets in a certain module. An Offset is the Startingpoint of a Channel in a sorted array of Digis.
| iBlock | is the Block/Module that is currently worked on |
Definition at line 120 of file Hitfinder.cxx.
References CalculateChannelOffsets(), channelOffsetPerModule, digiOffsetPerModule, digisPerModule, GetNDigis(), and nChannels.
Referenced by FindClustersSingleStep().
|
inlineprivate |
Definition at line 350 of file Hitfinder.h.
Referenced by CreateClusterFromConnectorsN().
|
inlineprivate |
Definition at line 346 of file Hitfinder.h.
|
inlineprivate |
Definition at line 348 of file Hitfinder.h.
|
private |
Definition at line 291 of file Hitfinder.cxx.
References AddCluster(), asic, CbmStsDigi::GetChannel(), CbmStsDigi::GetChargeU16(), CbmStsDigi::GetTimeU32(), IsBackside(), nChannels, and SaveMaxError().
Referenced by CalculateClustersParallel().
|
private |
Definition at line 313 of file Hitfinder.cxx.
References AddCluster(), asic, CbmStsDigi::GetChannel(), CbmStsDigi::GetChargeU16(), CbmStsDigi::GetTimeU32(), IsBackside(), LandauWidth(), nChannels, cbm::algo::sts::DigiConnector::next(), SaveMaxError(), and x.
Referenced by CalculateClustersParallel().
|
private |
Definition at line 386 of file Hitfinder.cxx.
References AddCluster(), asic, ChanDist(), cbm::algo::sts::ClusterCalculationProperties::chanF, cbm::algo::sts::ClusterCalculationProperties::chanL, cbm::algo::sts::ClusterCalculationProperties::eqFsq, cbm::algo::sts::ClusterCalculationProperties::eqLsq, cbm::algo::sts::ClusterCalculationProperties::eqMsq, CbmStsDigi::GetChannel(), CbmStsDigi::GetChargeU16(), CbmStsDigi::GetTimeU32(), IsBackside(), LandauWidth(), nChannels, cbm::algo::sts::DigiConnector::next(), cbm::algo::sts::ClusterCalculationProperties::qF, cbm::algo::sts::ClusterCalculationProperties::qL, cbm::algo::sts::ClusterCalculationProperties::qM, SaveMaxError(), cbm::algo::sts::ClusterCalculationProperties::tResolSum, cbm::algo::sts::ClusterCalculationProperties::tSum, x, and cbm::algo::sts::ClusterCalculationProperties::xSum.
Referenced by CalculateClustersParallel().
|
private |
Definition at line 829 of file Hitfinder.cxx.
References cbm::algo::sts::ClusterIdx::fIdx, cbm::algo::sts::ClusterIdx::fTime, cbm::algo::sts::Cluster::fTimeError, hitsAllocatedPerModule, hitsPerModule, maxHitsPerModule, monitor, nHitsPerModule, and ToGlobal().
Referenced by IntersectClusters().
|
private |
| XPU_D void sts::Hitfinder::FindClustersParallel | ( | FindClusters::context & | ctx | ) | const |
sts::Hitfinder::findClustersParallel This function finds clusters form an sts-Digi Array inserted. It runs the finding process highly parallel.
| iBlock | is the Block/Module that is currently worked on |
Definition at line 141 of file Hitfinder.cxx.
References channelOffsetPerModule, digiConnectorsPerModule, digiOffsetPerModule, digisPerModule, CbmStsDigi::GetChannel(), GetNDigis(), GetTimeDiff(), GetTimeResolution(), nChannels, nModules, cbm::algo::RecoParams::STS::timeCutDigiAbs, and cbm::algo::RecoParams::STS::timeCutDigiSig.
Referenced by FindClustersSingleStep().
| XPU_D void sts::Hitfinder::FindClustersSingleStep | ( | FindClusters::context & | ctx | ) | const |
Definition at line 73 of file Hitfinder.cxx.
References CalculateClustersParallel(), CalculateOffsetsParallel(), and FindClustersParallel().
| XPU_D void sts::Hitfinder::FindHits | ( | FindHits::context & | ctx | ) | const |
Definition at line 518 of file Hitfinder.cxx.
References cbm::algo::RecoParams::STS::chargeCorrelationDelta, clusterDataPerModule, clusterIdxSortedPerModule, cbm::algo::RecoParams::STS::doChargeCorrelation, cbm::algo::sts::HitfinderCache::dX, cbm::algo::sts::SensorPar::dY, cbm::algo::sts::HitfinderCache::errorFac, cbm::algo::sts::Cluster::fCharge, cbm::algo::sts::ClusterIdx::fIdx, cbm::algo::sts::Cluster::fTimeError, GetTimeDiff(), IntersectClusters(), cbm::algo::kFindHitsChunksPerModule, cbm::algo::sts::SensorPar::lorentzB, cbm::algo::sts::SensorPar::lorentzF, maxClustersPerModule, maxClusterTimeErrorByModuleSide, maxHitsPerModule, nChannels, nClustersPerModule, nHitsPerModule, nModules, cbm::algo::sts::SensorPar::pitch, sensorPars, cbm::algo::sts::SensorPar::stereoB, cbm::algo::sts::SensorPar::stereoF, cbm::algo::sts::HitfinderCache::tanStereoB, cbm::algo::sts::HitfinderCache::tanStereoF, cbm::algo::RecoParams::STS::timeCutClusterAbs, and cbm::algo::RecoParams::STS::timeCutClusterSig.
|
private |
Definition at line 742 of file Hitfinder.cxx.
References cbm::algo::sts::SensorPar::lorentzB, cbm::algo::sts::SensorPar::lorentzF, nChannels, and cbm::algo::sts::SensorPar::pitch.
Referenced by IntersectClusters().
|
inlineprivate |
Definition at line 330 of file Hitfinder.h.
References digiOffsetPerModule.
Referenced by CalculateClustersParallel(), CalculateOffsetsParallel(), FindClustersParallel(), and SortDigisInSpaceAndTime().
|
inlineprivate |
Definition at line 390 of file Hitfinder.h.
References CbmStsDigi::GetTimeU32().
Referenced by FindClustersParallel(), and FindHits().
|
inlineprivate |
Definition at line 397 of file Hitfinder.h.
References cbm::algo::sts::ClusterIdx::fTime.
|
inlineprivate |
|
private |
Definition at line 768 of file Hitfinder.cxx.
References cbm::algo::sts::HitfinderCache::dX, cbm::algo::sts::SensorPar::dY, cbm::algo::sts::HitfinderCache::errorFac, IsInside(), cbm::algo::sts::SensorPar::stereoB, cbm::algo::sts::SensorPar::stereoF, cbm::algo::sts::HitfinderCache::tanStereoB, cbm::algo::sts::HitfinderCache::tanStereoF, x, and y.
Referenced by IntersectClusters().
|
private |
Definition at line 681 of file Hitfinder.cxx.
References CreateHit(), cbm::algo::sts::HitfinderCache::dX, cbm::algo::sts::SensorPar::dY, cbm::algo::sts::Cluster::fPosition, cbm::algo::sts::Cluster::fPositionError, GetClusterPosition(), Intersect(), cbm::algo::sts::SensorPar::pitch, cbm::algo::sts::SensorPar::stereoB, cbm::algo::sts::SensorPar::stereoF, cbm::algo::sts::HitfinderCache::tanStereoB, and cbm::algo::sts::HitfinderCache::tanStereoF.
Referenced by FindHits().
|
inlineprivate |
Definition at line 337 of file Hitfinder.h.
References nChannels.
|
inlineprivate |
Definition at line 374 of file Hitfinder.h.
References nModules.
Referenced by CreateClusterFromConnectors1(), CreateClusterFromConnectors2(), and CreateClusterFromConnectorsN().
|
private |
Definition at line 819 of file Hitfinder.cxx.
References cbm::algo::sts::HitfinderCache::dX, cbm::algo::sts::SensorPar::dY, x, and y.
Referenced by Intersect().
|
private |
Definition at line 875 of file Hitfinder.cxx.
References landauStepSize, landauTable, and landauTableSize.
Referenced by CreateClusterFromConnectors2(), and CreateClusterFromConnectorsN().
|
inlineprivate |
Definition at line 399 of file Hitfinder.h.
References maxClusterTimeErrorByModuleSide.
Referenced by CreateClusterFromConnectors1(), CreateClusterFromConnectors2(), and CreateClusterFromConnectorsN().
| XPU_D void sts::Hitfinder::SortClusters | ( | SortClusters::context & | ctx | ) | const |
Definition at line 480 of file Hitfinder.cxx.
References clusterIdxPerModule, clusterIdxPerModuleTmp, clusterIdxSortedPerModule, cbm::algo::sts::ClusterIdx::fTime, maxClustersPerModule, nClustersPerModule, and nModules.
| XPU_D void sts::Hitfinder::SortDigisInSpaceAndTime | ( | SortDigis::context & | ctx | ) | const |
sts::Hitfinder::sortDigisKhun Sorts digis channelwise. Inside a channel all digis are sorted in time.
| smem | is the shared memory it is worked in |
| iBlock | is the Block/Module that is currenty running |
Definition at line 52 of file Hitfinder.cxx.
References digiOffsetPerModule, digisPerModule, digisPerModuleTmp, CbmStsDigi::GetChannel(), GetNDigis(), and CbmStsDigi::GetTimeU32().
|
private |
Definition at line 889 of file Hitfinder.cxx.
References localToGlobalRotationByModule, and localToGlobalTranslationByModule.
Referenced by CreateHit().
| sts::HitfinderPars::Asic cbm::algo::sts::Hitfinder::asic |
Definition at line 207 of file Hitfinder.h.
Referenced by CreateClusterFromConnectors1(), CreateClusterFromConnectors2(), CreateClusterFromConnectorsN(), and GetTimeResolution().
| xpu::buffer<unsigned int> cbm::algo::sts::Hitfinder::channelOffsetPerModule |
Definition at line 242 of file Hitfinder.h.
Referenced by CalculateOffsetsParallel(), and FindClustersParallel().
| xpu::buffer<sts::Cluster> cbm::algo::sts::Hitfinder::clusterDataPerModule |
Definition at line 265 of file Hitfinder.h.
Referenced by AddCluster(), and FindHits().
| xpu::buffer<ClusterIdx> cbm::algo::sts::Hitfinder::clusterIdxPerModule |
Definition at line 251 of file Hitfinder.h.
Referenced by AddCluster(), and SortClusters().
| xpu::buffer<ClusterIdx> cbm::algo::sts::Hitfinder::clusterIdxPerModuleTmp |
Definition at line 255 of file Hitfinder.h.
Referenced by SortClusters().
| xpu::buffer<ClusterIdx*> cbm::algo::sts::Hitfinder::clusterIdxSortedPerModule |
Definition at line 260 of file Hitfinder.h.
Referenced by FindHits(), and SortClusters().
| xpu::buffer<DigiConnector> cbm::algo::sts::Hitfinder::digiConnectorsPerModule |
Definition at line 237 of file Hitfinder.h.
Referenced by CalculateClustersParallel(), and FindClustersParallel().
| xpu::buffer<size_t> cbm::algo::sts::Hitfinder::digiOffsetPerModule |
Definition at line 228 of file Hitfinder.h.
Referenced by CalculateClustersParallel(), CalculateOffsetsParallel(), FindClustersParallel(), GetNDigis(), and SortDigisInSpaceAndTime().
| xpu::buffer<CbmStsDigi> cbm::algo::sts::Hitfinder::digisPerModule |
Definition at line 229 of file Hitfinder.h.
Referenced by CalculateClustersParallel(), CalculateOffsetsParallel(), FindClustersParallel(), and SortDigisInSpaceAndTime().
| xpu::buffer<CbmStsDigi> cbm::algo::sts::Hitfinder::digisPerModuleTmp |
Definition at line 232 of file Hitfinder.h.
Referenced by SortDigisInSpaceAndTime().
| size_t cbm::algo::sts::Hitfinder::hitsAllocatedPerModule |
Definition at line 279 of file Hitfinder.h.
Referenced by CreateHit().
| xpu::buffer<sts::Hit> cbm::algo::sts::Hitfinder::hitsFlat |
Definition at line 299 of file Hitfinder.h.
| size_t cbm::algo::sts::Hitfinder::hitsFlatCapacity |
Definition at line 298 of file Hitfinder.h.
| xpu::buffer<sts::Hit> cbm::algo::sts::Hitfinder::hitsPerModule |
Definition at line 290 of file Hitfinder.h.
Referenced by CreateHit().
| float cbm::algo::sts::Hitfinder::landauStepSize |
Definition at line 210 of file Hitfinder.h.
Referenced by LandauWidth().
| xpu::buffer<float> cbm::algo::sts::Hitfinder::landauTable |
Definition at line 212 of file Hitfinder.h.
Referenced by LandauWidth().
| int cbm::algo::sts::Hitfinder::landauTableSize |
Definition at line 209 of file Hitfinder.h.
Referenced by LandauWidth().
| xpu::buffer<float> cbm::algo::sts::Hitfinder::localToGlobalRotationByModule |
Definition at line 217 of file Hitfinder.h.
Referenced by ToGlobal().
| xpu::buffer<float> cbm::algo::sts::Hitfinder::localToGlobalTranslationByModule |
Definition at line 216 of file Hitfinder.h.
Referenced by ToGlobal().
| size_t cbm::algo::sts::Hitfinder::maxClustersPerModule |
Definition at line 245 of file Hitfinder.h.
Referenced by AddCluster(), FindHits(), and SortClusters().
| xpu::buffer<PaddedToCacheLine<float> > cbm::algo::sts::Hitfinder::maxClusterTimeErrorByModuleSide |
Definition at line 274 of file Hitfinder.h.
Referenced by FindHits(), and SaveMaxError().
| size_t cbm::algo::sts::Hitfinder::maxHitsPerModule |
Definition at line 285 of file Hitfinder.h.
Referenced by CreateHit(), and FindHits().
| xpu::buffer<HitfinderMonDevice> cbm::algo::sts::Hitfinder::monitor |
Definition at line 224 of file Hitfinder.h.
Referenced by AddCluster(), and CreateHit().
| int cbm::algo::sts::Hitfinder::nChannels |
Definition at line 205 of file Hitfinder.h.
Referenced by CalculateChannelOffsets(), CalculateOffsetsParallel(), CreateClusterFromConnectors1(), CreateClusterFromConnectors2(), CreateClusterFromConnectorsN(), FindClustersParallel(), FindHits(), GetClusterPosition(), and IsActive().
| xpu::buffer<PaddedToCacheLine<int> > cbm::algo::sts::Hitfinder::nClustersPerModule |
Definition at line 270 of file Hitfinder.h.
Referenced by AddCluster(), FindHits(), and SortClusters().
| xpu::buffer<PaddedToCacheLine<int> > cbm::algo::sts::Hitfinder::nHitsPerModule |
Definition at line 295 of file Hitfinder.h.
Referenced by CreateHit(), and FindHits().
| int cbm::algo::sts::Hitfinder::nModules |
Definition at line 204 of file Hitfinder.h.
Referenced by CalculateClustersParallel(), FindClustersParallel(), FindHits(), IsBackside(), and SortClusters().
| xpu::buffer<SensorPar> cbm::algo::sts::Hitfinder::sensorPars |
Definition at line 221 of file Hitfinder.h.
Referenced by FindHits().