Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compile issue #10

Open
muskie82 opened this issue Jun 7, 2021 · 2 comments
Open

Compile issue #10

muskie82 opened this issue Jun 7, 2021 · 2 comments

Comments

@muskie82
Copy link

muskie82 commented Jun 7, 2021

Hello.

I failed to build the source code.
The error message is,

/home/hide/hide_ws/mvs/PlaneSweepLib/src/PSL/psl_cudaBase/cudaFishEyeImageProcessor.cpp: In member function ‘std::pair<PSL_CUDA::DeviceImage, PSL::FishEyeCameraMatrix<double> > PSL_CUDA::CudaFishEyeImageProcessor::undistort(double, double, double, double, double, double)’:
/home/hide/hide_ws/mvs/PlaneSweepLib/src/PSL/psl_cudaBase/cudaFishEyeImageProcessor.cpp:78:92: error: no matching function for call to ‘make_pair<PSL_CUDA::DeviceImage, PSL::FishEyeCameraMatrix<double> >(PSL_CUDA::DeviceImage&, PSL::FishEyeCameraMatrix<double>&)’
     return std::make_pair<DeviceImage, FishEyeCameraMatrix<double> >(outputImage, newCamera);
                                                                                            ^
In file included from /usr/include/c++/7/bits/stl_algobase.h:64:0,
                 from /usr/include/c++/7/bits/char_traits.h:39,
                 from /usr/include/c++/7/ios:40,
                 from /usr/include/c++/7/istream:38,
                 from /usr/include/c++/7/sstream:38,
                 from /home/hide/hide_ws/mvs/PlaneSweepLib/src/PSL/psl_cudaBase/cudaCommon.h:21,
                 from /home/hide/hide_ws/mvs/PlaneSweepLib/src/PSL/psl_cudaBase/deviceImage.h:21,
                 from /home/hide/hide_ws/mvs/PlaneSweepLib/src/PSL/psl_cudaBase/cudaFishEyeImageProcessor.h:21,
                 from /home/hide/hide_ws/mvs/PlaneSweepLib/src/PSL/psl_cudaBase/cudaFishEyeImageProcessor.cpp:18:
/usr/include/c++/7/bits/stl_pair.h:524:5: note: candidate: template<class _T1, class _T2> constexpr std::pair<typename std::__decay_and_strip<_Tp>::__type, typename std::__decay_and_strip<_T2>::__type> std::make_pair(_T1&&, _T2&&)
     make_pair(_T1&& __x, _T2&& __y)
     ^~~~~~~~~
/usr/include/c++/7/bits/stl_pair.h:524:5: note:   template argument deduction/substitution failed:
/home/hide/hide_ws/mvs/PlaneSweepLib/src/PSL/psl_cudaBase/cudaFishEyeImageProcessor.cpp:78:92: note:   cannot convert ‘outputImage’ (type ‘PSL_CUDA::DeviceImage’) to type ‘PSL_CUDA::DeviceImage&&’
     return std::make_pair<DeviceImage, FishEyeCameraMatrix<double> >(outputImage, newCamera);
                                                                                            ^
src/PSL/CMakeFiles/PSL.dir/build.make:1545: recipe for target 'src/PSL/CMakeFiles/PSL.dir/psl_cudaBase/cudaFishEyeImageProcessor.cpp.o' failed
make[2]: *** [src/PSL/CMakeFiles/PSL.dir/psl_cudaBase/cudaFishEyeImageProcessor.cpp.o] Error 1
CMakeFiles/Makefile2:174: recipe for target 'src/PSL/CMakeFiles/PSL.dir/all' failed

Has anyone met this error before?
I use Ubuntu 18.04 and CUDA 11.1 .

Sincerely,

@minxuanjun
Copy link

You can try to replace "std::make_pair<DeviceImage, FishEyeCameraMatrix >(outputImage, newCamera)" with {outputImage, newCamera}

@muskie82
Copy link
Author

@minxuanjun
Thanks, it works.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants