# OpenCV vs ITK

**URL:** https://discourse.itk.org/t/opencv-vs-itk/2174
**Category:** Beginner Questions
**Tags:** python
**Created:** [August 20, 2019, 1:31am UTC](https://discourse.itk.org/t/opencv-vs-itk/2174 "2019-08-20T01:31:35Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![Jigabytes](https://discourse.itk.org/user_avatar/discourse.itk.org/jigabytes/32/967_2.png) [@Jigabytes](https://discourse.itk.org/u/Jigabytes)
#### Post date: [August 20, 2019, 1:31am UTC](https://discourse.itk.org/t/opencv-vs-itk/2174/1 "2019-08-20T01:31:35Z")

</div>

Hi,

```
 I am new to Dicom modality image segmentation and analysis. I was playing with Python and opencv for 2D image segmentation. Next I am exploring python with Itk to solve 3D Segmentation problems.

```

Can throw some light on using itk vs openCV for image segmentation in general ?

Thanks,  
Jiten

---

<div class="post-metadata">

### Author: ![matt.mccormick](https://discourse.itk.org/user_avatar/discourse.itk.org/matt.mccormick/32/7_2.png) [@matt.mccormick](https://discourse.itk.org/u/matt.mccormick)
#### Post date: [August 20, 2019, 1:45am UTC](https://discourse.itk.org/t/opencv-vs-itk/2174/2 "2019-08-20T01:45:19Z")

</div>

Hi Jiten,

Welcome to the ITK Community! ☀

In general, you will find that ITK has better support for reading DICOM data, working with anisotropic images, 3D datasets.

ITK has many useful segmentation methods, but many modern segmentations solutions involve combining ITK with machine learning and deep learning libraries like scikit-learn, tensorflow, or pytorch.

Hope this helps,  
Matt

---

<div class="post-metadata">

### Author: ![Jigabytes](https://discourse.itk.org/user_avatar/discourse.itk.org/jigabytes/32/967_2.png) [@Jigabytes](https://discourse.itk.org/u/Jigabytes)
#### Post date: [August 20, 2019, 2:32am UTC](https://discourse.itk.org/t/opencv-vs-itk/2174/3 "2019-08-20T02:32:37Z")

</div>

Thanks Matt for your response. Looking forward to build some good segmentation algos with help to itk and other relevant libraries.

---

<div class="post-metadata">

### Author: ![Jigabytes](https://discourse.itk.org/user_avatar/discourse.itk.org/jigabytes/32/967_2.png) [@Jigabytes](https://discourse.itk.org/u/Jigabytes)
#### Post date: [August 20, 2019, 2:53am UTC](https://discourse.itk.org/t/opencv-vs-itk/2174/4 "2019-08-20T02:53:48Z")

</div>

Hi Matt,

```
          In multidimensional segmentation, let's say 3D Dicom image, we apply Segmentation on each slice of 2D images to collectively get 3Dsegmentation results ?

```

Thanks,  
Jiten

---

<div class="post-metadata">

### Author: ![dzenanz](https://discourse.itk.org/user_avatar/discourse.itk.org/dzenanz/32/1093_2.png) [@dzenanz](https://discourse.itk.org/u/dzenanz)
#### Post date: [August 20, 2019, 2:36pm UTC](https://discourse.itk.org/t/opencv-vs-itk/2174/5 "2019-08-20T14:36:04Z")

</div>

That is called 2.5D (two and a half dimensional) approach, frequently employed when the library does not fully support 3D. Also used when the author likes to think in 2D terms. It almost always delivers inferior results compared to a full 3D approach. ITK makes it easy to work with full data dimensionality, which is usually 3D.
