Skip to content

Commit

Permalink
code format
Browse files Browse the repository at this point in the history
  • Loading branch information
luopeichao committed Apr 12, 2021
1 parent aa7ef81 commit 81e6551
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 22 deletions.
22 changes: 11 additions & 11 deletions mmcv/ops/csrc/parrots/roi_align_rotated.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -71,18 +71,18 @@ void roi_align_rotated_forward_cpu(Tensor features, Tensor rois, Tensor output,
int pooled_height, int pooled_width,
float spatial_scale, int sample_num,
bool aligned, bool clockwise) {
ROIAlignRotatedForwardCPULauncher(
features, rois, output, pooled_height, pooled_width, spatial_scale,
ROIAlignRotatedForwardCPULauncher(features, rois, output, pooled_height,
pooled_width, spatial_scale,
sample_num, aligned, clockwise);
}

void roi_align_rotated_backward_cpu(Tensor features, Tensor rois, Tensor output,
int pooled_height, int pooled_width,
float spatial_scale, int sample_num,
bool aligned, bool clockwise) {
ROIAlignRotatedBackwardCPULauncher(
features, rois, output, pooled_height, pooled_width, spatial_scale,
sample_num, aligned, clockwise);
int pooled_height, int pooled_width,
float spatial_scale, int sample_num,
bool aligned, bool clockwise) {
ROIAlignRotatedBackwardCPULauncher(features, rois, output, pooled_height,
pooled_width, spatial_scale, sample_num,
aligned, clockwise);
}

void roi_align_rotated_forward(Tensor input, Tensor rois, Tensor output,
Expand Down Expand Up @@ -133,8 +133,8 @@ void roi_align_rotated_backward(Tensor grad_output, Tensor rois,
CHECK_CPU_INPUT(rois);
CHECK_CPU_INPUT(grad_input);

roi_align_rotated_backward_cpu(grad_output, rois, grad_input,
pooled_height, pooled_width, spatial_scale,
sample_num, aligned, clockwise);
roi_align_rotated_backward_cpu(grad_output, rois, grad_input, pooled_height,
pooled_width, spatial_scale, sample_num,
aligned, clockwise);
}
}
8 changes: 4 additions & 4 deletions mmcv/ops/csrc/parrots/roi_align_rotated_parrots.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,8 @@ void roi_align_rotated_forward_cpu_parrots(HostContext& ctx,
const auto& rois = buildATensor(ctx, ins[1]);
auto output = buildATensor(ctx, outs[0]);
roi_align_rotated_forward_cpu(input, rois, output, pooled_height,
pooled_width, spatial_scale, sample_num,
aligned, clockwise);
pooled_width, spatial_scale, sample_num,
aligned, clockwise);
}

void roi_align_rotated_backward_cpu_parrots(HostContext& ctx,
Expand All @@ -111,8 +111,8 @@ void roi_align_rotated_backward_cpu_parrots(HostContext& ctx,
const auto& rois = buildATensor(ctx, ins[1]);
auto grad_input = buildATensor(ctx, outs[0]);
roi_align_rotated_backward_cpu(grad_output, rois, grad_input, pooled_height,
pooled_width, spatial_scale, sample_num,
aligned, clockwise);
pooled_width, spatial_scale, sample_num,
aligned, clockwise);
}

PARROTS_EXTENSION_REGISTER(roi_align_rotated_forward)
Expand Down
14 changes: 7 additions & 7 deletions mmcv/ops/csrc/parrots/roi_align_rotated_pytorch.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,14 @@ void roi_align_rotated_backward_cuda(Tensor grad_output, Tensor rois,
#endif

void roi_align_rotated_forward_cpu(Tensor features, Tensor rois, Tensor output,
int pooled_height, int pooled_width,
float spatial_scale, int sample_num,
bool aligned, bool clockwise);
int pooled_height, int pooled_width,
float spatial_scale, int sample_num,
bool aligned, bool clockwise);

void roi_align_rotated_backward_cpu(Tensor grad_output, Tensor rois,
Tensor bottom_grad, int pooled_height,
int pooled_width, float spatial_scale,
int sample_num, bool aligned,
bool clockwise);
Tensor bottom_grad, int pooled_height,
int pooled_width, float spatial_scale,
int sample_num, bool aligned,
bool clockwise);

#endif // ROI_ALIGN_ROTATED_PYTORCH_H

0 comments on commit 81e6551

Please sign in to comment.