提交 ba786b2e 编写于 作者: W wangyang59

only do test_ConvUnify when there is a gpu

上级 60bf1a47
......@@ -94,6 +94,7 @@ MatrixPtr doOneConvTest(size_t imgSize, size_t output_x, size_t stride,
}
TEST(Layer, convParaUnified) {
#ifndef PADDLE_ONLY_CPU
MatrixPtr input, resultCpu, resultGpu;
input = Matrix::create(1, 4 * 4, false, false);
float inputData[] = {1, 2, 3, 4,
......@@ -155,6 +156,7 @@ TEST(Layer, convParaUnified) {
/*numfilters*/ 2,
input, param2, true);
checkMatrixEqual(resultCpu, resultGpu);
#endif
}
int main(int argc, char** argv) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册