Find the weights or kernel used by gaussian_filter of scipy.ndimage

Viewed 255

I am having an image consisting of {0,1,2} values and I am trying to run gaussian_filter from scipy.ndimage over it. Though it was very easy to use but I haven't understood the things properly yet.

Few things that I understood are :

  • sigma is the standard deviation used for assigning weights in the kernel
  • Gaussian filter on a 2D image is implemented in the form of 1D gaussian filters
  • the size of the kernel depends upon sigma as well as truncate value [Gaussian filter in scipy

I want to know the weights being used in the gaussian filter. Is there some way to get the kernel used from the gaussian_filter call itself or some formula by which I can have that kernel.

I want this just for better understanding of weightage I am giving to different neighboring pixels in my image.

for example what will be kernel for

ndimage.gaussian_filter(image,sigma=0.2)

ndimage.gaussian_filter(image,sigma=0.2,truncate=2)

0 Answers
Related