From 6c528cbc2acd6f24c56c7ef5bcb0e29702092df3 Mon Sep 17 00:00:00 2001 From: xzl Date: Fri, 21 Jul 2017 11:37:19 +0800 Subject: [PATCH] add check: CHECK_EQ(outputs[0].getArgType(), ADD_TO) --- paddle/function/DepthwiseConvOp.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/paddle/function/DepthwiseConvOp.cpp b/paddle/function/DepthwiseConvOp.cpp index 21084bedb4..490e8d546c 100644 --- a/paddle/function/DepthwiseConvOp.cpp +++ b/paddle/function/DepthwiseConvOp.cpp @@ -172,6 +172,7 @@ public: void calc(const BufferArgs& inputs, const BufferArgs& outputs) override { CHECK_EQ(numInputs_, inputs.size()); CHECK_EQ(numOutputs_, outputs.size()); + CHECK_EQ(outputs[0].getArgType(), ADD_TO); check(inputs, outputs); CHECK_EQ(outputs[0].getArgType(), ADD_TO); const TensorShape& output = inputs[0].shape(); @@ -235,6 +236,7 @@ public: void calc(const BufferArgs& inputs, const BufferArgs& outputs) override { CHECK_EQ(numInputs_, inputs.size()); CHECK_EQ(numOutputs_, outputs.size()); + CHECK_EQ(outputs[0].getArgType(), ADD_TO); check(inputs, outputs); const TensorShape& output = inputs[0].shape(); const TensorShape& input = inputs[1].shape(); -- GitLab