From 39745d448ca75433fdb93fb01192b4ba55976344 Mon Sep 17 00:00:00 2001 From: Double_V Date: Wed, 21 Oct 2020 10:10:56 +0800 Subject: [PATCH] Roi align kl (#28128) * add rois_num params for roi_align_xpu op, test=kunlun * fix xpu roi_align_op warning,test=kunlun --- paddle/fluid/operators/roi_align_op_xpu.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/paddle/fluid/operators/roi_align_op_xpu.cc b/paddle/fluid/operators/roi_align_op_xpu.cc index 75bd94142e6..699cc7b84a4 100644 --- a/paddle/fluid/operators/roi_align_op_xpu.cc +++ b/paddle/fluid/operators/roi_align_op_xpu.cc @@ -62,7 +62,7 @@ class XPUROIAlignOpKernel : public framework::OpKernel { } else { auto _rois_lod = rois->lod().back(); rois_batch_size = _rois_lod.size() - 1; - for (int n = 0; n < _rois_lod.size(); ++n) { + for (int n = 0; n < static_cast(_rois_lod.size()); ++n) { rois_lod[n] = _rois_lod[n]; } PADDLE_ENFORCE_EQ( -- GitLab