Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
1.1k views
in Technique[技术] by (71.8m points)

image processing - How to do a Gaussian filtering in 3D

How do i do a gaussi smoothing in the 3th dimension?

I have this detection pyramid, votes accumulated at four scales. Objects are found at each peak.

Detection Pyramid

I already smoothed each of them in 2d, and reading in my papers that i need to filter the third dimension with a sigma = 1, which i havent tried before, i am not even sure what it means.

I Figured out how to do it in Matlab, and need something simular in opencv/c++.

Matlab Raw Values: Raw Matlab Smoothen with M0 = smooth3(M0,'gaussian'); : Smooth

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

Gaussian filters are separable. You apply 1D filter at each dimension as follows:

for (dim = 0; dim < D; dim++)
    tensor = gaussian_filter(tensor, dim);

I would recommend OpenCV for an implementation of a gaussian filter (and image processing in general) in C++.

Note that this assumes that your pyramid levels are all of the same size. You can have your own functions that sample your scale-space pyramid on the fly while convolving the third dimension, but if you have enough memory I believe that it would be faster to scale up your coarser level to have the same size of the finest level.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...