File indexing completed on 2026-07-26 08:22:00
0001
0002
0003
0004
0005
0006
0007
0008 #pragma once
0009
0010
0011 #include "traccc/definitions/common.hpp"
0012 #include "traccc/definitions/primitives.hpp"
0013 #include "traccc/definitions/qualifiers.hpp"
0014
0015 namespace traccc {
0016
0017 struct seedfinder_config {
0018 seedfinder_config() { setup(); }
0019
0020
0021 float zMin = -2000.f * unit<float>::mm;
0022 float zMax = 2000.f * unit<float>::mm;
0023 float rMax = 200.f * unit<float>::mm;
0024
0025
0026 float rMin = 33.f * unit<float>::mm;
0027
0028
0029
0030
0031 float collisionRegionMin = -250 * unit<float>::mm;
0032 float collisionRegionMax = +250 * unit<float>::mm;
0033 float phiMin = static_cast<float>(-M_PI);
0034 float phiMax = static_cast<float>(M_PI);
0035
0036
0037
0038 float minPt = 500.f * unit<float>::MeV;
0039
0040
0041 float cotThetaMax = 27.2845f;
0042
0043 float deltaRMin = 20 * unit<float>::mm;
0044
0045 float deltaRMax = 80 * unit<float>::mm;
0046
0047
0048 float deltaZMax = 450 * unit<float>::mm;
0049
0050
0051
0052
0053
0054
0055
0056
0057
0058
0059
0060 float impactMax = 10.f * unit<float>::mm;
0061
0062 float sigmaScattering = 3.0f;
0063
0064 float maxPtScattering = 10.f * unit<float>::GeV;
0065
0066
0067 unsigned int maxSeedsPerSpM = 5;
0068
0069 float bFieldInZ = 1.99724f * unit<float>::T;
0070
0071
0072 vector2 beamPos{-.0f * unit<float>::mm, -.0f * unit<float>::mm};
0073
0074
0075
0076
0077
0078 float radLengthPerSeed = 0.05f;
0079
0080
0081
0082
0083
0084
0085 float zAlign = 0 * unit<float>::mm;
0086 float rAlign = 0 * unit<float>::mm;
0087
0088
0089 float sigmaError = 5;
0090
0091
0092 float highland = 0;
0093 float maxScatteringAngle2 = 0;
0094 float pTPerHelixRadius = 0;
0095 float minHelixDiameter2 = 0;
0096 float minHelixRadius = 0;
0097 float pT2perRadius = 0;
0098
0099
0100
0101
0102
0103
0104
0105 int phiBinDeflectionCoverage = 1;
0106
0107 std::array<unsigned int, 2> neighbor_scope{1, 1};
0108
0109 TRACCC_HOST_DEVICE
0110 size_t get_num_rbins() const {
0111 return static_cast<size_t>(rMax + vector::norm(beamPos));
0112 }
0113
0114 TRACCC_HOST_DEVICE
0115 unsigned int get_max_neighbor_bins() const {
0116 unsigned int t = neighbor_scope[0] + neighbor_scope[1] + 1;
0117 return t * t;
0118 }
0119
0120
0121 TRACCC_HOST_DEVICE
0122 void setup() {
0123 highland = 13.6f * traccc::unit<float>::MeV * std::sqrt(radLengthPerSeed) *
0124 (1.f + 0.038f * std::log(radLengthPerSeed));
0125
0126 float maxScatteringAngle = highland / minPt;
0127 maxScatteringAngle2 = maxScatteringAngle * maxScatteringAngle;
0128
0129 pTPerHelixRadius = bFieldInZ;
0130 minHelixDiameter2 = std::pow(minPt * 2.f / pTPerHelixRadius, 2.f);
0131 minHelixRadius = std::sqrt(minHelixDiameter2) / 2.f;
0132
0133
0134
0135 pT2perRadius = std::pow(highland / pTPerHelixRadius, 2.f);
0136 }
0137 };
0138
0139
0140 struct spacepoint_grid_config {
0141 spacepoint_grid_config() = delete;
0142 spacepoint_grid_config(const seedfinder_config& finder_config)
0143 : bFieldInZ(finder_config.bFieldInZ),
0144 minPt(finder_config.minPt),
0145 rMax(finder_config.rMax),
0146 zMax(finder_config.zMax),
0147 zMin(finder_config.zMin),
0148 deltaRMax(finder_config.deltaRMax),
0149 cotThetaMax(finder_config.cotThetaMax),
0150 impactMax(finder_config.impactMax),
0151 phiMin(finder_config.phiMin),
0152 phiMax(finder_config.phiMax),
0153 phiBinDeflectionCoverage(finder_config.phiBinDeflectionCoverage) {}
0154
0155
0156 float bFieldInZ;
0157
0158 float minPt;
0159
0160
0161 float rMax;
0162
0163
0164 float zMax;
0165
0166
0167 float zMin;
0168
0169
0170 float deltaRMax;
0171
0172 float cotThetaMax;
0173
0174 float impactMax;
0175
0176 float phiMin = static_cast<float>(-M_PI);
0177
0178 float phiMax = static_cast<float>(M_PI);
0179
0180
0181
0182
0183
0184
0185 int phiBinDeflectionCoverage = 1;
0186 };
0187
0188 struct seedfilter_config {
0189
0190
0191 float deltaInvHelixDiameter = 0.00003f / unit<float>::mm;
0192
0193
0194 float impactWeightFactor = 1.f;
0195
0196 float compatSeedWeight = 200.f;
0197
0198
0199 float deltaRMin = 5.f * unit<float>::mm;
0200
0201
0202 size_t compatSeedLimit = 2;
0203
0204
0205 float good_spB_min_radius = 150.f * unit<float>::mm;
0206 float good_spB_weight_increase = 400.f;
0207 float good_spT_max_radius = 150.f * unit<float>::mm;
0208 float good_spT_weight_increase = 200.f;
0209
0210
0211 float good_spB_min_weight = 380.f;
0212
0213
0214 float seed_min_weight = 200.f;
0215 float spB_min_radius = 43.f * unit<float>::mm;
0216 };
0217
0218 }