[Insight-users] Gaussian of masked images

Atwood, Robert C r.atwood at imperial.ac.uk
Mon Jul 5 11:23:37 EDT 2004


I could really use this as well. The idea would be to reduce noise, only
in the volume that is already determined to be a certain phase  by some
other method, but leave the other phase alone, and especially not
diffuse some of the other phase's gray scale into the first phase.

I can do this in my own code but it would be a steep learning curve to
do it in itk-compatible style (and my supervisor would wonder what the
heck I was doing)

For an "average" filter it goes something like this:


neighbour_count = 0;
total=0.0;
if (voxel_greyscale <= threshold)/* this could be another condition such
as : if (voxel_bitmask == 1 ) */
{   
    for [[all neighbours]] 
    {
       if (neigbour_greyscale <= threshold) /* this could be another
condition such as : if (neighbour_bitmask == 1 ) */
       { 
          total += neighbour_greyscale;
          neighbour_count++;
       }
   }
new_voxel_greyscale = total/neigbour_count; /* put average into the
voxel value */
}


Robert
 

-----Original Message-----
From: insight-users-bounces at itk.org
[mailto:insight-users-bounces at itk.org] On Behalf Of Luis Ibanez
Sent: 02 July 2004 22:35
To: Kai Li
Cc: insight-users at itk.org
Subject: Re: [Insight-users] Gaussian of masked images



Hi Kai,

Do you want to exclude some pixels from being input to the Gaussian ?

or to you want to exclude some pixels from receiving the result of the
Gaussian computation ?

The first one may not be a very formal operation...

What is the purpose of excluding those pixels ?


Please let us know,


    Thanks


     Luis


-------------
Kai Li wrote:

> Hi Luis,
>    Thanks for your information, but what I exactly want is a filter 
> for "masked" image. This may looks weird you. What I meant is that 
> some pixels in a, say, grey image do not take part in the computation 
> of the Gaussian.
> 
> Thanks,
> Kai
> 
> On Fri, 2 Jul 2004, Luis Ibanez wrote:
> 
> 
>>Hi Kai,
>>
>>If you are using large Gaussians you will find more
>>efficient to use the LaplacianRecursiveGaussian filter
>>
>>http://www.itk.org/Insight/Doxygen/html/classitk_1_1LaplacianRecursive
>>GaussianImageFilter.html
>>
>>This filter internally uses IIR filters and therefore
>>its computation time is independent of the size of your sigma.
>>
>>You will find examples on the use of this filter in the
>>files
>>
>>
>>   Insight/Examples/Filtering/
>>        LaplacianRecursiveGaussianImageFilter1.cxx
>>        LaplacianRecursiveGaussianImageFilter2.cxx
>>        ScaleSpaceGenerator2D.cxx
>>
>>
>>
>>
>>   Regards,
>>
>>
>>     Luis
>>
>>
>>
>>-------------
>>Kai Li wrote:
>>
>>
>>>Hi,
>>>  I'm in a situation where Laplacian of Gaussian(LoG) of masked 
>>>images has to be computed. I'm wondering if ITK has already provided 
>>>something to archieve this.
>>>
>>>  The method that I can come up with at this point is to use a 
>>>Difference-Of-Gaussian operator that can compute the Gaussian 
>>>derivatives for each pixel and mask the kernel of the operator 
>>>dynamically for each pixel. This method seems OK but not efficient 
>>>for the computation in large scale(sigma).
>>>
>>>  Any suggestion is highly appreciated.
>>>
>>>Kai
>>>_______________________________________________
>>>Insight-users mailing list
>>>Insight-users at itk.org 
>>>http://www.itk.org/mailman/listinfo/insight-users
>>>
>>
>>
>>
> _______________________________________________
> Insight-users mailing list
> Insight-users at itk.org 
> http://www.itk.org/mailman/listinfo/insight-users
> 



_______________________________________________
Insight-users mailing list
Insight-users at itk.org http://www.itk.org/mailman/listinfo/insight-users


More information about the Insight-users mailing list