Ask Your Question
0

opencv error: failed assertion

asked 2014-05-29 16:10:13 -0600

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

edit retag flag offensive close merge delete

Comments

1

a gaussian kernel needs to be odd size

berak gravatar imageberak ( 2014-05-29 16:13:24 -0600 )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 ( 2014-05-30 10:43:56 -0600 )edit

dear, RTFM

so, gaussianSize has to be odd.

berak gravatar imageberak ( 2014-05-30 11:04:54 -0600 )edit

1 answer

Sort by ยป oldest newest most voted
0

answered 2014-05-30 12:10:50 -0600

Olfa gravatar image

ok thanks

edit flag offensive delete link more

Question Tools

Stats

Asked: 2014-05-29 16:10:13 -0600

Seen: 4,974 times

Last updated: May 29 '14