|
7 | 7 | #define THREADS 512 |
8 | 8 |
|
9 | 9 | __global__ void instance_iou_cuda_kernel( |
10 | | - long total_gt_instances, const long* __restrict__ nInstance, int nProposal, |
11 | | - const long* __restrict__ proposals_idx, const long* __restrict__ proposals_offset, |
12 | | - const long* __restrict__ instance_labels, const long* __restrict__ offset_num_gt_instances, |
13 | | - const long* __restrict__ batch, const long* __restrict__ instance_pointnum, |
| 10 | + int64_t total_gt_instances, const int64_t* __restrict__ nInstance, int nProposal, |
| 11 | + const int64_t* __restrict__ proposals_idx, const int64_t* __restrict__ proposals_offset, |
| 12 | + const int64_t* __restrict__ instance_labels, const int64_t* __restrict__ offset_num_gt_instances, |
| 13 | + const int64_t* __restrict__ batch, const int64_t* __restrict__ instance_pointnum, |
14 | 14 | float* proposals_iou) |
15 | 15 | { |
16 | 16 | for (int proposal_id = blockIdx.x; proposal_id < nProposal; proposal_id += gridDim.x) |
@@ -44,18 +44,18 @@ __global__ void instance_iou_cuda_kernel( |
44 | 44 |
|
45 | 45 | // input: proposals_idx (sumNPoint), int |
46 | 46 | // input: proposals_offset (nProposal + 1), int |
47 | | -// input: instance_labels (N), long, 0~total_nInst-1, -100 |
| 47 | +// input: instance_labels (N), int64_t, 0~total_nInst-1, -100 |
48 | 48 | // input: instance_pointnum (total_nInst), int |
49 | 49 | // output: proposals_iou (nProposal, total_nInst), float |
50 | | -void instance_iou_kernel_wrapper(long total_gt_instances, long max_gt_instances, |
51 | | - const long* nInstance, int nProposal, const long* proposals_idx, |
52 | | - const long* proposals_offset, const long* instance_labels, |
53 | | - const long* offset_num_gt_instances, const long* batch, |
54 | | - const long* instance_pointnum, float* proposals_iou) |
| 50 | +void instance_iou_kernel_wrapper(int64_t total_gt_instances, int64_t max_gt_instances, |
| 51 | + const int64_t* nInstance, int nProposal, const int64_t* proposals_idx, |
| 52 | + const int64_t* proposals_offset, const int64_t* instance_labels, |
| 53 | + const int64_t* offset_num_gt_instances, const int64_t* batch, |
| 54 | + const int64_t* instance_pointnum, float* proposals_iou) |
55 | 55 | { |
56 | 56 | auto stream = at::cuda::getCurrentCUDAStream(); |
57 | 57 | instance_iou_cuda_kernel<<<std::min(nProposal, THREADS * THREADS), |
58 | | - std::min(max_gt_instances, (long)THREADS), 0, stream>>>( |
| 58 | + std::min(max_gt_instances, (int64_t)THREADS), 0, stream>>>( |
59 | 59 | total_gt_instances, nInstance, nProposal, proposals_idx, proposals_offset, instance_labels, |
60 | 60 | offset_num_gt_instances, batch, instance_pointnum, proposals_iou); |
61 | 61 | } |
0 commit comments