update paddle_inference_api_anakin_engine.cc with cuda sync (#12037)

guochaorong-patch-1
石晓伟 7 years ago committed by Yan Chunwei
parent a7c1ed123c
commit 0b9abcbe75

@ -54,6 +54,7 @@ bool PaddleInferenceAnakinPredictor::Run(
LOG(ERROR) << "copy data from CPU to GPU error";
return false;
}
cudaStreamSynchronize(NULL);
}
executor_.prediction();
@ -76,6 +77,7 @@ bool PaddleInferenceAnakinPredictor::Run(
LOG(ERROR) << "copy data from GPU to CPU error";
return false;
}
cudaStreamSynchronize(NULL);
}
return true;
}

Loading…
Cancel
Save