提交 f8d799d9 编写于 作者: Y yangfei

repair bug of test-gpu

上级 41578c1f
......@@ -15,15 +15,20 @@ limitations under the License. */
#include <iostream>
#include "../test_helper.h"
#include "../test_include.h"
#include "../../src/common/types.h"
int main() {
paddle_mobile::PaddleMobile<paddle_mobile::GPU_CL> paddle_mobile;
paddle_mobile::PaddleMobile<paddle_mobile::CPU> paddle_mobile;
// paddle_mobile.SetThreadNum(4);
auto time1 = paddle_mobile::time();
// auto isok = paddle_mobile.Load(std::string(g_mobilenet_detect) + "/model",
// std::string(g_mobilenet_detect) + "/params", true);
paddle_mobile.SetCLPath(".");
auto isok = paddle_mobile.Load(std::string(g_mobilenet), true);
#ifdef PADDLE_MOBILE_CL
paddle_mobile.SetCLPath("/data/local/tmp/bin");
#endif
auto isok = paddle_mobile.Load(std::string(g_mobilenet_mul) + "/model",
std::string(g_mobilenet_mul) + "/params", true);
// auto isok = paddle_mobile.Load(std::string(g_mobilenet_mul), true);
if (isok) {
auto time2 = paddle_mobile::time();
std::cout << "load cost :" << paddle_mobile::time_diff(time1, time2) << "ms"
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册