[Insight-users] [Re] Correct use of MRIBiasFieldCorrectionFilter ?

karmonik karmonik@bcm.tmc.edu
Tue, 25 Feb 2003 11:21:38 -0600


Hi Martin,

thanks for your email.

Yes, I am using a single class, an imput mask (a filled cirlce to get rid of 
the background) and an output mask (same as the input mask).

More specifically, I convert the original pixel values (which are in the range 
of 0-8000) to floating point values (normalized to 1) first. Then, I create a 
histogram and find the mean of the pixel value distribution (in the case of 
the image I sent it is about 0.3) and estimate the sigma (to about 0.5, but as 
I use only one class this value should not be too critical as long as it is 
large enough, right?)
Both input and output mask are also floating point values (with value 1 for 
inside the mask and value 0 for outside).

The BiasCorrection example uses values of 0 for cshrink, 1.05 for cgrowth and 
1.02 for the initial radius. 
I turned off interslice correction (I have only one slice anyway) and also set 
cshrink to 0.9.
I run the filter with Debug enabled so it shows me the convergence of the 
f-norm value. 
All this seems to work fine technically, however, the results are not too good 
(so I run into local minima) and I believe it might be due to the starting 
values of the legendre coefficients or the combination of cshrink and cgrowth 
or the degree of the Legendre polynoms.

The image you see is a sample holder filled with water and the remaining 
slices also show axial cuts through thin sample tubes emerged in the sample 
holder. 
I pretty much have only one class (the water), the samples are too small to 
create another class.
I believe I cannot use the background as a second class as there is not MRI 
intensity (just air).

I will keep trying and thanks for your email. I like the concept of this 
filter a lot and I would really like to get it to work.


Thanks !


Christof


>===== Original Message From Martin Styner <martin_styner@ieee.org> =====
>Hi Christof, Jinsung
>
>Jinsung is quite right in his answer,  but in my experience there
>shouldn't be too much problems selecting the mean values and the
>standard deviation values, unless the image is quite complex and  the
>values are far off. The image that you provided seems to have only one
>single class, is that correct? Did you model this as a single class
>correction problem or did you also use the background as an additional
>class? If so then you need to mask the background, since the background
>should not be modeled as a class, because the bias field does not affect
>the background. As single class problem, the class parameter values
>should not be too sensitive (I only adjust the other values e.g. c_grow
>in few exceptional cases) , but also I never used the bias correction in
>images with only one class.
>Can you tell us the classes and their values that you chose for the
>particular image you attached to your email?
>In regard to the use of other basis functions: It is not necessary to
>use Legendre polynomials for the bias correction, any set of basis
>functions should theoretically be applicable. Although I would suggest
>if you try a different set of basis functions, just make sure to use
>orthogonal ones (orthonormal would be even better, Btw, the Legendre
>polynomials are orthogonal and not orthonormal).
>
>When browsing through the itk-class description, I saw that the
>inter-slice brightness correction is applied by default. In general,
>this is actually not necessary (only for older MRI's it should be
>necessary to do this). So, maybe turning off the inter-slice correction
>could help.
>
>Btw, since I am not at UNC anymore: can someone update the links to the
>papers in the doxygen documentation?
>for the TMI paper:
>http://www.cs.unc.edu/~gerig/publications/TMI00-Styner-Bias.pdf
>for the TR:
>http://www.vision.ee.ethz.ch/db_queries/get_abstract.cgi?techreps:Styner97a
>
>One more question for Jinsung: Is the itk implementation using
>sub-sampling for the energy-computation? If so, which sub-sampling is it
>using. I think, it would be good if one could actually adjust the
>subsampling factor (in order to speed up the computation). Otherwise, I
>think you did a great job with this itk-class.
>
>Regards
>Martin
>
>
>Jisung Kim wrote:
>>>Hi there,
>>>
>>
>> Hi. I'm the person who ported the algorithm to ITK.
>> Martin Styner would know much better than me. However,
>> I will try to answer your questions.
>>
>>
>>>I am using the MRIBiasFieldCorrectionFilter to
>>>correct the bias field of a MRI
>>>surface coil (see attached image).
>>>
>>
>>>The class itself works fine, I am able to input and
>>>output all the
>>>parameters,the image and the masks.
>>>
>>
>>>However, so far I was not able to obtain a good
>>>correction. The estimated bias
>>>field is incorrect. So, I must be doing something
>>>wrong. (The filter finds
>>>local minima instead of the global minimum).
>>>
>>
>> It's hard to get a good result when you don't know
>> good initial statistics of the tissue classes. Martin
>> Styner suggested in his paper to select a small region
>> where pixels of all the tissue classes exist and then
>> pick the means of intensities values of tissue classes
>> in that region. Selecting the standard deviations for
>> the tissue classes is a little bit trickier than
>> selecting means. You can use the EnergyTablePlotter
>> utility that will be under the "your ITK binary
>> directory"/bin directory. you can see the usage by
>> typing the command without any commmand line
>> arguments. The utility will print energy values in a
>> table format. You can pipe that result to a file and
>> view energy function plot using mathematical packages
>> such as GNU R or matlab. The plot shows a good
>> separation between tissue class means. If you increase
>> the standard deviations, the the picks between tissue
>> class means would be lower. You want the picks are
>> higher than 0.5 (in energy value).
>>
>>
>>>Could anybody suggest good values for cshrink,
>>>cgrow, x0 as well as the
>>>coefficients for the legendre polynoms? I tried
>>>without success the parameter
>>>value ranges suggested in the references.
>>>
>>
>> I think if you have good statistics of tissue classes,
>> then you might get a reasonable result without
>> changing the shrink factors. However, if you want to
>> the optimization scheme works in a finer scales, use
>> smaller values.
>>
>>
>>>Does anybody have experience with this filter?
>>>
>>
>>>Is it possible to use a basis set other than the
>>>Legendre Polynoms (i.e.
>>>Gaussians?)
>>>
>>
>> I am not sure whether current implementaion of the
>> filter works with basis functions other than Legendre
>> Plynoms. However, since the ITK optimization framework
>> expects a class that has the interfaces defined by the
>> SingleValuedCostFunction, it wouldn't be hard to use
>> other base functions. I might have to double check it
>> and change a little bit.
>>
>> Thanks,
>>
>>
>>>It would be a pity if this elegant correction
>>>algorithm only worked for the
>>>examples given in the two references ....
>>>
>>
>>>Thanks
>>>
>>
>>>Christof
>>>
>>
>>>Christof Karmonik, PhD
>>>Baylor College of Medicine/The Methodist Hospital
>>>Mailstation M217
>>>6565 Fannin
>>>Houston, TX 77030
>>>Pager: (713) 708-2232
>>>Fax: (713) 790-4688
>>>
>>
>> =====
>> Jisung Kim
>> bahrahm@yahoo.com
>> 106 Mason Farm Rd.
>> 129 Radiology Research Lab., CB# 7515
>> Univ. of North Carolina at Chapel Hill
>> Chapel Hill, NC 27599-7515
>>
>> __________________________________________________
>> Do you Yahoo!?
>> Yahoo! Tax Center - forms, calculators, tips, more
>> http://taxes.yahoo.com/
>> _______________________________________________
>> Insight-users mailing list
>> Insight-users@public.kitware.com
>> http://public.kitware.com/mailman/listinfo/insight-users
>
>--
>---------------------------------------------------
>Martin Styner, PhD. Ing. ETH
>Group Head - Medical Image Analysis (MIA)
>M.E.Mueller Research Center for Orthopaedic Surgery
>Institute for Surgical Technology and Biomechanics
>University of Bern
>Murtenstr. 35,  P.O. Box 8354
>CH-3001 Bern, Switzerland
>Tel:   +41 31 632 0940
>Fax:   +41 31 632 4951
>Email: Martin.Styner@MEMcenter.unibe.ch
>http://www.MEMcenter.unibe.ch
>---------------------------------------------------
>
>_______________________________________________
>Insight-users mailing list
>Insight-users@public.kitware.com
>http://public.kitware.com/mailman/listinfo/insight-users

Christof Karmonik, PhD
Baylor College of Medicine/The Methodist Hospital
Mailstation M217
6565 Fannin
Houston, TX 77030
Pager: (713) 708-2232
Fax: (713) 790-4688