文档链接在此:getGaussianKernel(int ksize, double sigma, int ktype=CV_64F)
Python:
cv2.getGaussianKernel(ksize, sigma[, ktype]) → retval
Parameters:
- ksize – Aperture size. It should be odd ( ksize m o d 2 = 1 ) ( \texttt{ksize} \mod 2 = 1 ) (ksizemod2=1) and positive.
- sigma – Gaussian standard deviation. If it is non-positive, it is computed from ksize as sigma = 0.3*((ksize-1)*0.5 - 1) + 0.8 .
- ktype – Type of filter coefficients. It can be CV_32F or CV_64F .
The function computes and returns the ksize × 1 \texttt{ksize} \times 1 ksize×