Single-Image-Example-Based-Super-Resolution
Single-Image-Example-Based-Super-Resolution copied to clipboard
Hello, I am interested in your code for Single-Image-Example-Based-Super-Resolution. I have a Question.
Hello, I am interested in your code for Single-Image-Example-Based-Super-Resolution. I have a Question.
After I do build the code by using the Example, I have no error message. But after I run the program I have some error message on the console,
OpenCV Error: Assertion failed (dims <= 2 && data && (unsigned)i0 < (unsigned)size.p[0] && (unsigned)(i1*DataType<_Tp>::channels) < (unsigned)(size.p[1]*channels()) && ((((sizeof(size_t)<<28)|0x8442211) >> ((DataType<_Tp>::depth) & ((1 << 3) - 1))*4) & 15) == elemSize1()) in cv::Mat::at, file c:\opencv\build\include\opencv2\core\mat.hpp, line 538
So, I tried debugging in the code.
While debugging,
in void gs::makeFreqResp(int filterSize, float p, float q, float s, cv::Mat& H, cv::Mat& G, cv::Mat& h, cv::Mat& g)
I had some error in /create the low pass magnitude response/ part.
in the for loop, in the else if (kTrans[i] == 1.0), after taking d = (1.0 + cos(wScaled[i]))*sqrt(2.0 - cos(wScaled[i])) / 2,
H.at
- when loading the image, can you verify that the image matrix is not empty?
- What build configs are you using? I find openCV works when using release configs but not debug configs.
Greg.