[Insight-users] xxxxxSPAMxxxxx xxxxxSPAMxxxxx Why the result of itk::MattesMutualInformationImageToImageMetric is negated?

Luis Ibanez luis.ibanez at kitware.com
Thu Mar 25 19:07:22 EDT 2010


Hi  水灵,

The value of Mutual information was returned as a negative
number to make this class easy to use with optimizers that
are set to "Minimize" the cost function by default.


This behavior is described in the documentation:

http://www.itk.org/Doxygen/html/classitk_1_1MattesMutualInformationImageToImageMetric.html#_details

See Note 1:

"Notes: 1. This class returns the negative mutual information value."


That said,

In practice, all ITK optimizer can be set to Maximize as well
as to Minimize. So, in retrospective, the Mattes Mutual Information
metric could have been returning the positive value of mutual
information.

It is probably too late now to
make any changes to its behavior.



      Regards,


            Luis


-------------------------------------------
2010/3/25 水灵 <348774226 at qq.com>:
> Hello!
>
> The last line of the GetValue() method in
> itkMattesMutualInformationImageToImageMetric.txx. It reads : return
> static_cast<MeasureType>( -1.0 * sum );
> why not : return static_cast<MeasureType>( sum ) ? Yet in other MI metric
> it's positive.
>
> thank you!
>
> Ling Luo
>
> _____________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Kitware offers ITK Training Courses, for more information visit:
> http://www.kitware.com/products/protraining.html
>
> Please keep messages on-topic and check the ITK FAQ at:
> http://www.itk.org/Wiki/ITK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.itk.org/mailman/listinfo/insight-users
>
>


More information about the Insight-users mailing list