# Metric to Compare two images using SimpleITK

**URL:** https://discourse.itk.org/t/metric-to-compare-two-images-using-simpleitk/3351
**Category:** Uncategorized
**Tags:** python, simpleitk
**Created:** [August 2, 2020, 3:22am UTC](https://discourse.itk.org/t/metric-to-compare-two-images-using-simpleitk/3351 "2020-08-02T03:22:22Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![unicorn](https://discourse.itk.org/letter_avatar_proxy/v4/letter/u/35a633/32.png) [@unicorn](https://discourse.itk.org/u/unicorn)
#### Post date: [August 2, 2020, 3:22am UTC](https://discourse.itk.org/t/metric-to-compare-two-images-using-simpleitk/3351/1 "2020-08-02T03:22:22Z")

</div>

Im currently using sitk and using conversions to numpy, I am able to perform few operations. I want to know the metrics that are available to compare two image. Is there any direct metric to find correlation between two images?

---

<div class="post-metadata">

### Author: ![zivy](https://discourse.itk.org/user_avatar/discourse.itk.org/zivy/32/1726_2.png) [@zivy](https://discourse.itk.org/u/zivy)
#### Post date: [August 2, 2020, 9:37pm UTC](https://discourse.itk.org/t/metric-to-compare-two-images-using-simpleitk/3351/2 "2020-08-02T21:37:46Z")

</div>

Hello @unicorn,

If you want to compare two images there are multiple similarity metrics that are part of the registration framework, including correlation which assumes a linear relationship (mathematically this is affine but most people refer to it as linear).

Please see [the registration overview](https://simpleitk.readthedocs.io/en/master/registrationOverview.html) and the set of registration notebooks in our [notebook repository](https://github.com/InsightSoftwareConsortium/SimpleITK-Notebooks) (6\* series). The `ImageRegistrationMethod.MetricEvaluate` function allows you to compare two images. Please also see [this related discussion](https://discourse.itk.org/t/rotate-the-image/3340).
