Image projections along an axis
Abstract
Image projection is a very common task in image analysis to reduce the dimension of an image. A base filter is provided, with some specialized filters which implement different projection methods.
Keywords
Source Code and Data
File
Image
Image
Select a file to preview
Reviews
James Miller
Saturday 11 February 2006
This submission provides a functor style filter to perform operations similar to the AccumulateImageFilter.
The difference with respect to the AccumulateImageFilter is that this filter is templated over a functor. This allows a variety of accumulation methods (mean, min, max, median, etc.). This makes a nice design, allowing it to be easily extended by providing a new functor to perform the “accumulation” of a dimension.
We have discussed extending the AccumulateImageFilter with additional methods using a set of modes. The functor style allows for the filter to be extended more easily.
The author indicates the AccumulateImageFilter cannot be modified to do this without jeapordizing backward compatibility. I offer two suggestions that may address this:
AccumulateImageFilter could be made a subclass of the ProjectionImageFilter, where the subclass specifies a functor that allows the current AccumulateImageFilter functionality (mean and sum).
Or, the AccumulateImageFilter could be extended to have an extra template parameter (the functor) but that template parameter will default to the function that provides the current AccumulateImageFilter functionality.
A comment on the API. The AccumulateImageFilter use Set/GetAccumulateDimension() methods to indicate the projection direction. The filter in this submission provides a Set/GetAxe() method. I suggest the Set/GetAxe be renamed to Set/GetAccumulateDimension(). Alternatively, the method could be Set/GetAxis(). However, in ITK we never refer to a dimension as an axis. So the method should really be Set/Get*Dimension() (perhaps Set/GetProjectionDimension()).
Todd Gable
Tuesday 5 December 2006
I found the AccumulateImageFilter incomplete, it only collapses the last dimension and with only the option to use the mean. The Image projection filter did exactly what I wanted with the flexibility of choosing which functor to use (mean, median, max, etc.). I was surprised something like this didn't already exist in ITK, Image projection should be added to an ITK release soon.
