From 762160bd8c3850a15a87467dd33edfd272469bfe Mon Sep 17 00:00:00 2001 From: qiaolongfei Date: Tue, 19 Jun 2018 23:42:57 +0800 Subject: [PATCH] fix concat grad kernel --- paddle/fluid/operators/math/concat.cu | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/paddle/fluid/operators/math/concat.cu b/paddle/fluid/operators/math/concat.cu index 6205f3cd85c..5863d74fca2 100644 --- a/paddle/fluid/operators/math/concat.cu +++ b/paddle/fluid/operators/math/concat.cu @@ -209,7 +209,7 @@ class ConcatGradFunctor { outputs_cols[0] = 0; for (int i = 0; i < o_num; ++i) { - int t_col = outputs->at(i)->numel() / out_row; + int t_col = ref_inputs.at(i)->numel() / out_row; if (sameShape) { if (t_col != out0_col) sameShape = false; } -- GitLab