Skip to content

Commit 5da4446

Browse files
author
Mark
committed
clang format
1 parent 8579d04 commit 5da4446

File tree

3 files changed

+24
-27
lines changed

3 files changed

+24
-27
lines changed

core/include/traccc/gbts_seeding/gbts_seeding_config.hpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,8 @@ struct gbts_seed_extraction_params {
118118
// max qual = add_hit*max_length*qual_scale
119119
float qual_scale =
120120
0.01f * static_cast<float>(INT_MAX) /
121-
(add_hit * static_cast<float>(traccc::device::gbts_consts::max_cca_iter));
121+
(add_hit *
122+
static_cast<float>(traccc::device::gbts_consts::max_cca_iter));
122123

123124
float inv_max_curvature = 900.0f;
124125
float max_z0 = 160.0f;

device/cuda/src/gbts_seeding/gbts_seeding_algorithm.cu

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -776,7 +776,8 @@ gbts_seeding_algorithm::output_type gbts_seeding_algorithm::operator()(
776776
cudaMemcpyAsync(&path_sizes, &ctx.d_counters[6], 2 * sizeof(unsigned int),
777777
cudaMemcpyDeviceToHost, stream);
778778

779-
TRACCC_DEBUG(path_sizes[0] << "size of path store | nTerminusEdges " << path_sizes[1]);
779+
TRACCC_DEBUG(path_sizes[0] << "size of path store | nTerminusEdges "
780+
<< path_sizes[1]);
780781

781782
cudaMalloc(&ctx.d_path_store,
782783
(path_sizes[0] + path_sizes[1]) * sizeof(int2));
@@ -806,9 +807,8 @@ gbts_seeding_algorithm::output_type gbts_seeding_algorithm::operator()(
806807
kernels::fit_segments<<<nBlocks, nThreads, 0, stream>>>(
807808
ctx.d_reducedSP, ctx.d_output_graph, ctx.d_path_store,
808809
ctx.d_seed_proposals, ctx.d_edge_bids, ctx.d_seed_ambiguity,
809-
ctx.d_levels, ctx.d_counters, path_sizes[1],
810-
m_config.minLevel, m_config.max_num_neighbours,
811-
m_config.seed_extraction_params);
810+
ctx.d_levels, ctx.d_counters, path_sizes[1], m_config.minLevel,
811+
m_config.max_num_neighbours, m_config.seed_extraction_params);
812812

813813
unsigned int nProps = 0;
814814
cudaMemcpyAsync(&nProps, &ctx.d_counters[8], sizeof(unsigned int),

device/cuda/src/gbts_seeding/kernels/GbtsGraphProcessingKernels.cuh

Lines changed: 18 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -67,13 +67,10 @@ struct Tracklet {
6767
* @param[internal] d_counters[5 and 6] used for counting the last block and
6868
* for the number of active edges
6969
*/
70-
__global__ static void CCA_IterationKernel(const int* d_output_graph,
71-
char* d_levels, int* d_active_edges,
72-
short2* d_outgoing_paths,
73-
unsigned int* d_counters, int iter,
74-
unsigned int nEdges,
75-
unsigned int max_num_neighbours,
76-
int minLevel) {
70+
__global__ static void CCA_IterationKernel(
71+
const int* d_output_graph, char* d_levels, int* d_active_edges,
72+
short2* d_outgoing_paths, unsigned int* d_counters, int iter,
73+
unsigned int nEdges, unsigned int max_num_neighbours, int minLevel) {
7774

7875
__shared__ unsigned int nEdgesLeft;
7976
unsigned int edge_size = 2 + 1 + max_num_neighbours;
@@ -554,16 +551,16 @@ inline __device__ void add_seed_proposal(const int qual, const int path_idx,
554551
}
555552
}
556553

557-
void __global__
558-
fit_segments(float4* d_sp_params, int* d_output_graph, int2* d_path_store,
559-
int2* d_seed_proposals, unsigned long long int* d_edge_bids,
560-
char* d_seed_ambiguity, char* d_levels, unsigned int* d_counters,
561-
unsigned int nTerminusEdges, int minLevel,
562-
unsigned int max_num_neighbours,
563-
gbts_seed_extraction_params seed_extraction_params) {
554+
void __global__ fit_segments(
555+
float4* d_sp_params, int* d_output_graph, int2* d_path_store,
556+
int2* d_seed_proposals, unsigned long long int* d_edge_bids,
557+
char* d_seed_ambiguity, char* d_levels, unsigned int* d_counters,
558+
unsigned int nTerminusEdges, int minLevel, unsigned int max_num_neighbours,
559+
gbts_seed_extraction_params seed_extraction_params) {
564560

565561
// take an extracted path and fit it to produce a quality score
566-
unsigned int path_idx = threadIdx.x + blockIdx.x * blockDim.x + nTerminusEdges;
562+
unsigned int path_idx =
563+
threadIdx.x + blockIdx.x * blockDim.x + nTerminusEdges;
567564
if (path_idx >= d_counters[7]) {
568565
return;
569566
}
@@ -605,13 +602,12 @@ fit_segments(float4* d_sp_params, int* d_output_graph, int2* d_path_store,
605602
if (length < minLevel) {
606603
return;
607604
}
608-
int qual = 0;
609-
if(toggle) {
610-
qual = static_cast<int>(seed_extraction_params.qual_scale * state2.m_J);
611-
}
612-
else {
613-
qual = static_cast<int>(seed_extraction_params.qual_scale * state1.m_J);
614-
}
605+
int qual = 0;
606+
if (toggle) {
607+
qual = static_cast<int>(seed_extraction_params.qual_scale * state2.m_J);
608+
} else {
609+
qual = static_cast<int>(seed_extraction_params.qual_scale * state1.m_J);
610+
}
615611
int prop_idx = atomicAdd(&d_counters[8], 1);
616612
// perform first round of bidding for disambiguation
617613
// only on the outermost edge

0 commit comments

Comments
 (0)