Ask Your Question
0

opencv error: failed assertion

asked May 29 '14

Olfa gravatar image

Hi, i try to detect the pupill and corners of eye with opencv et qt but when i choose an image to execute my code. qtcreator display this error "OpenCV Error: Assertion failed (ksize.width > 0 && ksize.width % 2 == 1 && ksize.height > 0 && ksize.height % 2 == 1) in createGaussianFilter, file /../../OpenCV-2.4.1/modules/imgproc/src/smooth.cpp, line 402" can anyone help me please

Preview: (hide)

Comments

1

a gaussian kernel needs to be odd size

berak gravatar imageberak (May 29 '14)edit

how can i do it. this is my line code where i use gaussian filter cv::GaussianBlur(srcClone, srcClone, cv::Size(gaussianSize, gaussianSize), 6, 6 ); srcClone is a grayscale image and gaussianSize are integer

Olfa gravatar imageOlfa (May 30 '14)edit

dear, RTFM

so, gaussianSize has to be odd.

berak gravatar imageberak (May 30 '14)edit

1 answer

Sort by » oldest newest most voted
0

answered May 30 '14

Olfa gravatar image

ok thanks

Preview: (hide)

Question Tools

Stats

Asked: May 29 '14

Seen: 5,328 times

Last updated: May 29 '14