Commit 63b6a2c4 authored by Dorothea Vom Bruch's avatar Dorothea Vom Bruch
Browse files

fix formatting

parent 3f8235b8
Pipeline #974569 passed with stage
in 1 minute and 28 seconds
......@@ -99,7 +99,7 @@ struct CheckerInvoker {
auto ids = track.ids();
std::sort(std::begin(ids), std::end(ids));
bool containsDuplicates = (std::unique(std::begin(ids), std::end(ids))) != std::end(ids);
if (containsDuplicates) {
if (containsDuplicates) {
warning_cout << "WARNING: Track #" << i_track << " contains duplicate LHCb IDs" << std::endl << std::hex;
for (auto id : ids) {
warning_cout << "0x" << id << ", ";
......
......@@ -95,10 +95,14 @@ TrackCheckerHistos::TrackCheckerHistos(const std::vector<HistoCategory>& histo_c
std::make_unique<TH1D>("matched_isMuon_P_reconstructed", "matched_isMuon_P_reconstructed", 10, 0., 100000.);
h_not_matched_isMuon_P_reconstructed =
std::make_unique<TH1D>("not_matched_isMuon_P_reconstructed", "not_matched_isMuon_P_reconstructed", 10, 0., 100000.);
h_muon_Pt_reconstructible = std::make_unique<TH1D>("muon_Pt_reconstructible", "muon_Pt_reconstructible", 30, 0., 5000.);
h_not_muon_Pt_reconstructible = std::make_unique<TH1D>("not_muon_Pt_reconstructible", "not_muon_Pt_reconstructible", 30, 0., 5000.);
h_matched_isMuon_Pt_reconstructed = std::make_unique<TH1D>("matched_isMuon_Pt_reconstructed", "matched_isMuon_Pt_reconstructed", 30, 0., 5000.);
h_not_matched_isMuon_Pt_reconstructed = std::make_unique<TH1D>("not_matched_isMuon_Pt_reconstructed", "not_matched_isMuon_Pt_reconstructed", 30, 0., 5000.);
h_muon_Pt_reconstructible =
std::make_unique<TH1D>("muon_Pt_reconstructible", "muon_Pt_reconstructible", 30, 0., 5000.);
h_not_muon_Pt_reconstructible =
std::make_unique<TH1D>("not_muon_Pt_reconstructible", "not_muon_Pt_reconstructible", 30, 0., 5000.);
h_matched_isMuon_Pt_reconstructed =
std::make_unique<TH1D>("matched_isMuon_Pt_reconstructed", "matched_isMuon_Pt_reconstructed", 30, 0., 5000.);
h_not_matched_isMuon_Pt_reconstructed =
std::make_unique<TH1D>("not_matched_isMuon_Pt_reconstructed", "not_matched_isMuon_Pt_reconstructed", 30, 0., 5000.);
h_muon_Phi_reconstructible =
std::make_unique<TH1D>("muon_Phi_reconstructible", "muon_Phi_reconstructible", 15, -3.142, 3.142);
......
......@@ -21,9 +21,9 @@ namespace SciFi {
namespace Tracking {
// The base PT threshold which is common to all algorithms
constexpr float minPt = 500 * Gaudi::Units::MeV;
constexpr float minPt = 500 * Gaudi::Units::MeV;
constexpr int max_scifi_hits = 20; // for x and u/v layers
constexpr int max_scifi_hits = 20; // for x and u/v layers
constexpr int nTrackParams = 9;
constexpr float tolYMag = 10. * Gaudi::Units::mm;
......@@ -44,7 +44,7 @@ namespace SciFi {
// z Reference plane
constexpr float zReference = 8520. * Gaudi::Units::mm; // in T2
constexpr float zRefInv = 1.f / zReference;
constexpr float zRefInv = 1.f / zReference;
// TODO: CHECK THESE VALUES USING FRAMEWORK
constexpr float xLim_Max = 3300.;
......@@ -53,12 +53,12 @@ namespace SciFi {
constexpr float yLim_Min = -25.;
// TO BE READ FROM XML EVENTUALLY
//constexpr float magscalefactor = -1;
// constexpr float magscalefactor = -1;
constexpr int zoneoffsetpar = 6;
struct Arrays {
// Returns whether the current layer is an X plane
const bool is_x_plane [12] {1, 0, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1};
const bool is_x_plane[12] {1, 0, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1};
// the Magnet Parametrization
// parameterized in offset [0], (slope difference due to kick)^2 [1],
......@@ -106,7 +106,7 @@ namespace SciFi {
2.246931985749485,
2.2797556995480273};
};
} // namespace Tracking
namespace Constants {
......
......@@ -19,7 +19,11 @@ __host__ __device__ float zMagnet(const MiniState& velo_state, const SciFi::Trac
__host__ __device__ float calcDxRef(float pt, const MiniState& velo_state);
__host__ __device__ float calcqOverP(float bx, const SciFi::Tracking::Arrays* constArrays, const MiniState& velo_state, const float magnet_polarity);
__host__ __device__ float calcqOverP(
float bx,
const SciFi::Tracking::Arrays* constArrays,
const MiniState& velo_state,
const float magnet_polarity);
__host__ __device__ float evalParameterizationX(const float* params, float z);
......
......@@ -41,7 +41,11 @@ __host__ __device__ float calcDxRef(float pt, const MiniState& velo_state)
return 3973000.f * sqrtf(m_slope2) / pt - 2200.f * ty2 - 1000.f * tx2; // tune this window
}
__host__ __device__ float calcqOverP(float bx, const SciFi::Tracking::Arrays* constArrays, const MiniState& velo_state, const float magnet_polarity)
__host__ __device__ float calcqOverP(
float bx,
const SciFi::Tracking::Arrays* constArrays,
const MiniState& velo_state,
const float magnet_polarity)
{
float qop = 1.0f / Gaudi::Units::GeV;
......@@ -100,9 +104,9 @@ __host__ __device__ void getTrackParameters(
__host__ __device__ float
trackToHitDistance(const float trackParameters[SciFi::Tracking::nTrackParams], const SciFi::Hits& scifi_hits, int hit)
{
const float z_Hit = scifi_hits.z0[hit] + scifi_hits.dzdy(hit) * evalParameterizationY(trackParameters + 4, scifi_hits.z0[hit]);
const float z_Hit =
scifi_hits.z0[hit] + scifi_hits.dzdy(hit) * evalParameterizationY(trackParameters + 4, scifi_hits.z0[hit]);
const float x_track = evalParameterizationX(trackParameters, z_Hit);
const float y_track = evalParameterizationY(trackParameters + 4, z_Hit);
return scifi_hits.x0[hit] + y_track * scifi_hits.dxdy(hit) - x_track;
}
......@@ -82,7 +82,7 @@ namespace UT {
// first add to sum values from hit at xMidField, zMidField hit
static constexpr float zDiff = 0.001f * (zKink - zMidUT);
//
constexpr float magFieldParams[3] = { 2010.0f, -2240.0f, -71330.f };
constexpr float magFieldParams[3] = {2010.0f, -2240.0f, -71330.f};
//
static constexpr float LD3Hits = -0.5f;
static constexpr float LD4Hits = -0.5f;
......
......@@ -363,7 +363,7 @@ __device__ void save_track(
}
const float evalParams[3] = {p, pt, finalParams[3]};
const float discriminant = evaluateLinearDiscriminant(evalParams, nHits);
if( discriminant < UT::Constants::LD3Hits ) return;
if (discriminant < UT::Constants::LD3Hits) return;
// the track will be added
int n_tracks = atomicAdd(n_veloUT_tracks, 1);
......
......@@ -51,34 +51,34 @@ __host__ __device__ float fastfitter(
const float zDiff = 0.001f * (zKink - UT::Constants::zMidUT);
// -- This is to avoid division by zero...
const float pHelper = std::max( float(std::abs(best_params.qp * qpxz2p)), float(1e-9));
const float invP = pHelper*sqrtf(1.0f+ty*ty);
const float pHelper = std::max(float(std::abs(best_params.qp * qpxz2p)), float(1e-9));
const float invP = pHelper * sqrtf(1.0f + ty * ty);
// these resolution are semi-empirical, could be tuned and might not be correct for low momentum.
// this is the resolution due to multiple scattering between Velo and UT
const float error1 = 0.14f + 10000.0f*invP;
const float error1 = 0.14f + 10000.0f * invP;
// this is the resolution due to the finite Velo resolution
const float error2 = 0.12f + 3000.0f*invP;
const float error = error1*error1 + error2*error2;
const float weight = 1.0f/error;
float mat[6] = {weight, weight * zDiff, weight * zDiff * zDiff, 0.0f, 0.0f, 0.0f};
float rhs[3] = {weight * xMidField, weight * xMidField * zDiff, 0.0f };
const float error2 = 0.12f + 3000.0f * invP;
const float error = error1 * error1 + error2 * error2;
const float weight = 1.0f / error;
float mat[6] = {weight, weight * zDiff, weight * zDiff * zDiff, 0.0f, 0.0f, 0.0f};
float rhs[3] = {weight * xMidField, weight * xMidField * zDiff, 0.0f};
const float yyProto = velo_state.y - velo_state.ty * velo_state.z;
for (int i = 0; i < UT::Constants::n_layers; ++i) {
if (best_hits[i] != -1) {
const auto hit = best_hits[i];
const int plane_code = i;
const float dxDy = ut_dxDy[plane_code];
const float yy = yyProto + (velo_state.ty * ut_hits.zAtYEq0[hit]);
const float ui = ut_hits.xAt(hit, yy, dxDy);
const float dz = 0.001f * (ut_hits.zAtYEq0[hit] - UT::Constants::zMidUT);
const float w = ut_hits.weight[hit];
const float t = ut_hits.sinT(hit, dxDy);
const float w = ut_hits.weight[hit];
const float t = ut_hits.sinT(hit, dxDy);
mat[0] += w;
mat[1] += w * dz;
mat[2] += w * dz * dz;
......@@ -91,7 +91,7 @@ __host__ __device__ float fastfitter(
rhs[2] += w * ui * t;
}
}
const float a11 = mat[2] * mat[5] - mat[4] * mat[4];
const float a12 = mat[4] * mat[3] - mat[1] * mat[5];
const float a13 = mat[1] * mat[4] - mat[2] * mat[3];
......
......@@ -25,24 +25,24 @@ VeloGeometry::VeloGeometry(std::vector<char> const& geometry)
{
char const* p = geometry.data();
auto copy_array = [this, &p] (const size_t N, float* d) {
const size_t n = ((size_t*)p)[0];
if (n != N) {
error_cout << n << " != " << N << std::endl;
}
p += sizeof(size_t);
memcpy(d, p, sizeof(float) * n);
p += sizeof(float) * n;
};
auto copy_array = [this, &p](const size_t N, float* d) {
const size_t n = ((size_t*) p)[0];
if (n != N) {
error_cout << n << " != " << N << std::endl;
}
p += sizeof(size_t);
memcpy(d, p, sizeof(float) * n);
p += sizeof(float) * n;
};
copy_array(Velo::Constants::n_modules, module_zs);
copy_array(Velo::Constants::number_of_sensor_columns, local_x);
copy_array(Velo::Constants::number_of_sensor_columns, x_pitch);
size_t n_ltg = ((size_t*)p)[0];
size_t n_ltg = ((size_t*) p)[0];
assert(n_ltg == Velo::Constants::n_sensors);
p += sizeof(size_t);
n_trans = ((size_t*)p)[0];
n_trans = ((size_t*) p)[0];
assert(n_trans == 12);
p += sizeof(size_t);
for (size_t i = 0; i < n_ltg; ++i) {
......
......@@ -3,9 +3,7 @@
/**
* @brief Calculates the parameters according to a root means square fit
*/
__device__ VeloState means_square_fit(
Velo::Consolidated::Hits& consolidated_hits,
const Velo::TrackHits& track)
__device__ VeloState means_square_fit(Velo::Consolidated::Hits& consolidated_hits, const Velo::TrackHits& track)
{
VeloState state;
......@@ -59,10 +57,7 @@ __device__ VeloState means_square_fit(
}
template<typename T>
__device__ void populate(
const Velo::TrackHits& track,
T* __restrict__ a,
const T* __restrict__ b)
__device__ void populate(const Velo::TrackHits& track, T* __restrict__ a, const T* __restrict__ b)
{
for (int i = 0; i < track.hitsNum; ++i) {
const auto hit_index = track.hits[i];
......@@ -111,7 +106,8 @@ __global__ void consolidate_velo_tracks(
populate<float>(track, consolidated_hits.x, float_dev_velo_cluster_container + 5 * number_of_hits + hit_offset);
populate<float>(track, consolidated_hits.y, float_dev_velo_cluster_container + hit_offset);
populate<float>(track, consolidated_hits.z, float_dev_velo_cluster_container + number_of_hits + hit_offset);
populate<uint32_t>(track, consolidated_hits.LHCbID, (uint32_t*) dev_velo_cluster_container + 2 * number_of_hits + hit_offset);
populate<uint32_t>(
track, consolidated_hits.LHCbID, (uint32_t*) dev_velo_cluster_container + 2 * number_of_hits + hit_offset);
// Calculate and store fit in consolidated container
VeloState beam_state = means_square_fit(consolidated_hits, track);
......
......@@ -51,7 +51,8 @@ __global__ void masked_velo_clustering(
const auto raw_event = VeloRawEvent(raw_input);
// process no neighbour sp
for (int raw_bank_number=threadIdx.x; raw_bank_number<raw_event.number_of_raw_banks; raw_bank_number+=blockDim.x) {
for (int raw_bank_number = threadIdx.x; raw_bank_number < raw_event.number_of_raw_banks;
raw_bank_number += blockDim.x) {
const auto module_number = raw_bank_number >> 2;
const uint cluster_start = module_cluster_start[module_number];
......@@ -99,8 +100,7 @@ __global__ void masked_velo_clustering(
float_velo_cluster_container[cluster_start + cluster_num] = gx;
float_velo_cluster_container[estimated_number_of_clusters + cluster_start + cluster_num] = gy;
float_velo_cluster_container[2 * estimated_number_of_clusters + cluster_start + cluster_num] = gz;
dev_velo_cluster_container[3 * estimated_number_of_clusters + cluster_start + cluster_num] =
get_lhcb_id(cid);
dev_velo_cluster_container[3 * estimated_number_of_clusters + cluster_start + cluster_num] = get_lhcb_id(cid);
}
// if there is a second cluster for this pattern
......@@ -127,8 +127,7 @@ __global__ void masked_velo_clustering(
float_velo_cluster_container[cluster_start + cluster_num] = gx;
float_velo_cluster_container[estimated_number_of_clusters + cluster_start + cluster_num] = gy;
float_velo_cluster_container[2 * estimated_number_of_clusters + cluster_start + cluster_num] = gz;
dev_velo_cluster_container[3 * estimated_number_of_clusters + cluster_start + cluster_num] =
get_lhcb_id(cid);
dev_velo_cluster_container[3 * estimated_number_of_clusters + cluster_start + cluster_num] = get_lhcb_id(cid);
}
}
}
......@@ -137,7 +136,7 @@ __global__ void masked_velo_clustering(
__syncthreads();
// Process rest of clusters
for (int candidate_number=threadIdx.x; candidate_number<number_of_candidates; candidate_number+=blockDim.x) {
for (int candidate_number = threadIdx.x; candidate_number < number_of_candidates; candidate_number += blockDim.x) {
const uint32_t candidate = cluster_candidates[candidate_number];
const uint8_t sp_index = candidate >> 11;
const uint8_t raw_bank_number = (candidate >> 3) & 0xFF;
......@@ -259,8 +258,8 @@ __global__ void masked_velo_clustering(
// Hits to the east, populated in the first 16 bits
(mask_east(current_cluster) & pixel_array[2]) |
// Hits in the current cluster with precedence in the latter 16 bits
(current_cluster & (start_pixel ^ -start_pixel ^
(~(-(start_pixel << 16)) & ((uint64_t) 0xFFFF000000000000) * ((col + 1) & 0x01))));
(current_cluster &
(start_pixel ^ -start_pixel ^ (~(-(start_pixel << 16)) & ((uint64_t) 0xFFFF000000000000) * ((col + 1) & 0x01))));
const int n = __popcll(current_cluster);
if (n > 0 && hits_with_precedence == 0) {
......@@ -297,8 +296,9 @@ __global__ void masked_velo_clustering(
const uint cluster_num = atomicAdd(module_cluster_num + module_number, 1);
#if DEBUG
const auto module_estimated_num = dev_module_cluster_start[Velo::Constants::n_modules * number_of_events + module_number + 1]
- dev_module_cluster_start[Velo::Constants::n_modules * number_of_events + module_number];
const auto module_estimated_num =
dev_module_cluster_start[Velo::Constants::n_modules * number_of_events + module_number + 1] -
dev_module_cluster_start[Velo::Constants::n_modules * number_of_events + module_number];
assert(cluster_num <= module_estimated_num);
#endif
......
......@@ -287,15 +287,14 @@ __global__ void fit_secondary_vertices(
// Track-PV association table.
const Associate::Consolidated::Table kalman_pv_ipchi2 {dev_kalman_pv_ipchi2, scifi_tracks.total_number_of_tracks};
const auto pv_table = kalman_pv_ipchi2.event_table(scifi_tracks, event_number);
// Kalman fitted tracks.
const ParKalmanFilter::FittedTrack* event_tracks = dev_kf_tracks + event_tracks_offset;
// Primary vertices.
const uint n_pvs_event = *(dev_number_of_multi_fit_vertices + event_number);
gsl::span<PV::Vertex const> vertices {dev_multi_fit_vertices + event_number * PV::max_number_vertices,
n_pvs_event};
gsl::span<PV::Vertex const> vertices {dev_multi_fit_vertices + event_number * PV::max_number_vertices, n_pvs_event};
// Secondary vertices.
VertexFit::TrackMVAVertex* event_secondary_vertices = dev_secondary_vertices + sv_offset;
......@@ -312,7 +311,7 @@ __global__ void fit_secondary_vertices(
// Don't fit SVs in events with no PVs.
// TODO: Decide how to handle events with no PVs.
if (n_pvs_event == 0) return;
const ParKalmanFilter::FittedTrack trackA = event_tracks[i_track];
// Preselection on first track.
......@@ -345,7 +344,7 @@ __global__ void fit_secondary_vertices(
// Fill extra info.
int ipv = pv_table.value[i_track] < pv_table.value[j_track] ? pv_table.pv[i_track] : pv_table.pv[j_track];
auto pv = vertices[ipv];
fill_extra_info(event_secondary_vertices[vertex_idx], pv, trackA, trackB);
fill_extra_info(event_secondary_vertices[vertex_idx], pv, trackA, trackB);
}
}
}
......@@ -112,9 +112,9 @@ namespace Consumers {
static constexpr size_t n_data_blocks = 27;
MuonLookupTables(
std::vector<char>& host_muon_tables_raw,
char*& dev_muon_tables_raw,
Muon::MuonTables*& muon_tables);
std::vector<char>& host_muon_tables_raw,
char*& dev_muon_tables_raw,
Muon::MuonTables*& muon_tables);
void consume(std::vector<char> const& data) override;
......
......@@ -49,7 +49,7 @@ void register_consumers(Allen::NonEventData::IUpdater* updater, Constants& const
tuple {Allen::NonEventData::MagneticField {},
std::make_unique<Consumers::MagneticField>(constants.dev_magnet_polarity)},
tuple {Allen::NonEventData::Beamline {}, std::make_unique<Consumers::Beamline>(constants.dev_beamline)},
tuple {Allen::NonEventData::VeloGeometry{}, std::make_unique<Consumers::VPGeometry>(constants)},
tuple {Allen::NonEventData::VeloGeometry {}, std::make_unique<Consumers::VPGeometry>(constants)},
tuple {Allen::NonEventData::MuonGeometry {},
std::make_unique<Consumers::MuonGeometry>(
constants.host_muon_geometry_raw, constants.dev_muon_geometry_raw, constants.dev_muon_geometry)},
......
template <typename Derived>
class GPUAlgorithm{};
template<typename Derived>
class GPUAlgorithm {
};
......@@ -234,7 +234,7 @@ __host__ void collectAllXHits_proto_p(
const MiniState& velo_state,
const MiniState& UT_state,
const float qOverP,
int side,
int side,
std::array<int, 2 * 6>& windows_x,
std::array<int, 2 * 6>& windows_uv,
std::array<float, 4 * 6>& parameters_uv,
......
......@@ -925,7 +925,6 @@ void filter_tracks_with_TMVA(
}
}
__host__ void collectAllXHits_proto_p(
const SciFi::Hits& scifi_hits,
const SciFi::HitCount& scifi_hit_count,
......@@ -941,10 +940,10 @@ __host__ void collectAllXHits_proto_p(
const SciFiWindowsParams& window_params,
const std::array<int, 12> true_scifi_indices_per_layer)
{
const float tx2 = velo_state.tx*velo_state.tx;
const float ty2 = velo_state.ty*velo_state.ty;
const float tx2 = velo_state.tx * velo_state.tx;
const float ty2 = velo_state.ty * velo_state.ty;
const float slope2 = tx2 + ty2;
const float pt = sqrtf(slope2 / (1.f + slope2) ) / fabsf(qOverP);
const float pt = sqrtf(slope2 / (1.f + slope2)) / fabsf(qOverP);
const float p = 1.f / std::abs(qOverP);
/* OPTIMIZE: possibly use these variables for wrong sign treatment */
......@@ -959,12 +958,12 @@ __host__ void collectAllXHits_proto_p(
// const float dir = q * SciFi::Tracking::magscalefactor * (-1.f); // needed for wrong sign treatment
// const float xTolWS = dx_calc(velo_state, qop_WS, window_params);
//const float q = qOverP > 0.f ? 1.f : -1.f;
//const float dir = q * magnet_polarity * (-1.f);
// const float q = qOverP > 0.f ? 1.f : -1.f;
// const float dir = q * magnet_polarity * (-1.f);
//const bool wSignTreatment = pt > SciFi::Tracking::wrongSignPT;
// const bool wSignTreatment = pt > SciFi::Tracking::wrongSignPT;
float zMag = zMagnet(velo_state, constArrays);
const float qop_WS = sqrtf(slope2 / (1.f + slope2) ) / pt;
const float qop_WS = sqrtf(slope2 / (1.f + slope2)) / pt;
// float dxRefWS = 0.f;
// if ( wSignTreatment ) {
// dxRefWS = 0.9f * calcDxRef(SciFi::Tracking::wrongSignPT, velo_state);
......@@ -973,7 +972,7 @@ __host__ void collectAllXHits_proto_p(
float xParams_seed[4] {xAtRef, UT_state.tx, 0, 0};
// use parametrization to propagate from UT to SciFi
const auto state_zRef = propagate_state_from_velo(UT_state, qOverP, 5); // zRef is between layers 4 and 5
const auto state_zRef = propagate_state_from_velo(UT_state, qOverP, 5); // zRef is between layers 4 and 5
const float xTol = dx_calc(velo_state, qOverP, window_params);
int iZoneStartingPoint = side > 0 ? constArrays->zoneoffsetpar : 0;
......@@ -984,7 +983,7 @@ __host__ void collectAllXHits_proto_p(
const auto izone_rel = iZone - iZoneStartingPoint;
const float zZone = constArrays->xZone_zPos[izone_rel];
//const int layer = constArrays->xZones[iZone] / 2;
// const int layer = constArrays->xZones[iZone] / 2;
const float dz_x = (zZone - SciFi::Tracking::zReference);
const float xInZone = scifi_propagation(state_zRef.x, UT_state.tx, qOverP, dz_x);
const float yInZone = yFromVelo(zZone, velo_state);
......@@ -1008,7 +1007,7 @@ __host__ void collectAllXHits_proto_p(
float xMax = xInZone + xTol;
/* OPTIMIZE: how do we take care of wrong sign tracks with momentum windows? */
//float xTolWS = 0.0;
// float xTolWS = 0.0;
// if (wSignTreatment) {
// // xTolWS = (zZone < SciFi::Tracking::zReference) ?
// // dxRefWS * zZone / SciFi::Tracking::zReference :
......@@ -1020,8 +1019,8 @@ __host__ void collectAllXHits_proto_p(
// // xMax = xInZone + xTolWS;
// // }
// debug_cout << "\t before WS treatment: xMin = " << xMin << ", xMax = " << xMax << ", WS = " << int(wSignTreatment) << ", pt = " << pt << std::endl;
// if (dir > 0) {
// debug_cout << "\t before WS treatment: xMin = " << xMin << ", xMax = " << xMax << ", WS = " <<
// int(wSignTreatment) << ", pt = " << pt << std::endl; if (dir > 0) {
// xMin = -1.f * xInZone - xTolWS;
// }
// else {
......@@ -1040,8 +1039,8 @@ __host__ void collectAllXHits_proto_p(
assert(itH >= x_zone_offset_begin && itH <= x_zone_offset_end);
assert(itEnd >= x_zone_offset_begin && itEnd <= x_zone_offset_end);
windows_x[2*izone_rel] = itH;
windows_x[2*izone_rel+1] = itEnd - itH;
windows_x[2 * izone_rel] = itH;
windows_x[2 * izone_rel + 1] = itEnd - itH;
// Now match the stereo hits
const float this_uv_z = constArrays->uvZone_zPos[izone_rel];
......@@ -1066,7 +1065,7 @@ __host__ void collectAllXHits_proto_p(
uv_zone_offset_begin + scifi_hit_count.zone_number_of_hits(constArrays->uvZones[iZone]);
/* OPTIMIZE: check how large the effect on the efficiency is to include the triangle hits */
// const int triangleOffset = side > 0 ? -1 : 1;
//assert(constArrays->uvZones[iZone + constArrays->zoneoffsetpar * triangleOffset] < SciFi::Constants::n_zones);
// assert(constArrays->uvZones[iZone + constArrays->zoneoffsetpar * triangleOffset] < SciFi::Constants::n_zones);
// const int triangle_zone_offset_begin =
// scifi_hit_count.zone_offset(constArrays->uvZones[iZone + constArrays->zoneoffsetpar * triangleOffset]);
// assert(constArrays->uvZones[iZone + constArrays->zoneoffsetpar * triangleOffset] < SciFi::Constants::n_zones);
......@@ -1077,8 +1076,7 @@ __host__ void collectAllXHits_proto_p(
int itUVEnd = getLowerBound(scifi_hits.x0, xMaxUV, uv_zone_offset_begin, uv_zone_offset_end);
// int itUV2 = getLowerBound(scifi_hits.x0, xMinUV, triangle_zone_offset_begin, triangle_zone_offset_end);
windows_uv[2*izone_rel] = itUVStart;
windows_uv[2*izone_rel+1] = itUVEnd;
windows_uv[2 * izone_rel] = itUVStart;
windows_uv[2 * izone_rel + 1] = itUVEnd;
}
}
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment