[Insight-developers] new RescaleIntensityImageFilter

Luis Ibanez luis.ibanez@kitware.com
Tue, 07 May 2002 11:10:27 -0400


Jim,


Lydia's method is probably a better fit for this case
than a mini-pipeline because the extra information of
the image is computed by a Calculator which is not a
filter.

The methods "BeforeThreadedGenerateData()" and
"AfterThreadedGenerateData" that you introduced are
great for this process. The parameters for the Functor
are computed in BeforeThreadedGenerateData() and the
actual conversion of intensity levels is left to the
Functor as it is normaly done by ThreadedGenerateData()
in the UnaryFunctorImageFilter base class.

the itkMinimumMaximumImageFilter and the Statistic filter
are still a bit out of the standard as far as the behavior
of the pipeline goes. Their outputs should be
"itkDoubleDataObjects" or something along those lines.


The main reason for creating this filter was to avoid
the "next" question from a user who asked yesterday how
to perform this process.  Our answer involved something
like using Events for connecting the itkMinimumMaximumImageFitler
and the itkShiftScaleImageFilter which looks pretty odd for a
process as simple as a linear transform on the image intensity.



the itkMinimumMaximumImageCalculator was moved to the
Code/BasicFilters directory. The test for
itkRescaleIntensityImageFilter was moved to BasicFilters too.



        Luis



===============================================================

Miller, James V (Research) wrote:
    > Luis,
    >
    > I haven't looked at your code yet but you could have also done what
    > Bill did in the NormalizeImageFilter.  The NormalizeImageFilter uses
    > a mini-pipeline and manages the mini-pipeline to move statistics
calculated
    > on one filter in the mini-pipeline to Set*() methods in another filter
    > in the mini-pipeline.
    >
    > The MinMaxCalculator should be moved into BasicFilters.
    >
    >
    >
    >
    >