From 37a9cff17650f197392db0fdfe593bf13824cfe8 Mon Sep 17 00:00:00 2001 From: gfuse Date: Mon, 23 Aug 2021 18:55:40 +0200 Subject: [PATCH] debug the side of arg 10 in kernel 1 --- GPU_version/vio/src/cl_class.cpp | 2 +- GPU_version/vio/src/frame_handler_mono.cpp | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/GPU_version/vio/src/cl_class.cpp b/GPU_version/vio/src/cl_class.cpp index c3af6a1..0a0b5a3 100644 --- a/GPU_version/vio/src/cl_class.cpp +++ b/GPU_version/vio/src/cl_class.cpp @@ -13,7 +13,7 @@ opencl::opencl(vk::AbstractCamera* cam):cam(cam) { std::vector all_devices; for(auto i:all_platforms){ std::cout << "Find platform number:"<< i.getInfo() << "\n"; - i.getDevices(CL_DEVICE_TYPE_GPU, &all_devices); + i.getDevices(CL_DEVICE_TYPE_CPU, &all_devices); } if (all_devices.size() == 0){ diff --git a/GPU_version/vio/src/frame_handler_mono.cpp b/GPU_version/vio/src/frame_handler_mono.cpp index 430f051..ff44ab1 100644 --- a/GPU_version/vio/src/frame_handler_mono.cpp +++ b/GPU_version/vio/src/frame_handler_mono.cpp @@ -61,8 +61,8 @@ FrameHandlerMono::FrameHandlerMono(vk::AbstractCamera* cam,Eigen::Matrixwrite_buf(1,8,9*300,H); cl_float3 J[300]; gpu_fast_->write_buf(1,9,300,J); - float chi2[1]={0.01}; - gpu_fast_->write_buf(1,10,1,chi2); + float chi2[300]={0.01}; + gpu_fast_->write_buf(1,10,300,chi2); klt_homography_init_=new initialization::KltHomographyInit(gpu_fast_); initialize(); }