# Slice 3D volume along a specific axis using python ITK

**URL:** https://discourse.itk.org/t/slice-3d-volume-along-a-specific-axis-using-python-itk/6005
**Category:** Beginner Questions
**Tags:** itk, dicom, python
**Created:** [June 21, 2023, 8:38am UTC](https://discourse.itk.org/t/slice-3d-volume-along-a-specific-axis-using-python-itk/6005 "2023-06-21T08:38:47Z")
**Posts on this page:** 1
**Showing post:** 2

<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: [June 21, 2023, 12:58pm UTC](https://discourse.itk.org/t/slice-3d-volume-along-a-specific-axis-using-python-itk/6005/2 "2023-06-21T12:58:06Z")

</div>

You could take a look at this thread:

> [@RegionOfInterestImageFilter to extract image slice from volume](https://discourse.itk.org/t/regionofinterestimagefilter-to-extract-image-slice-from-volume/4787):
>
> Hello, I’d like to extract a 2D slice from a MRI NIfTI file. I believe the RegionOfInterestImageFilter function in itk will do the job: [https://itk.org/ITKExamples/src/Filtering/ImageGrid/ExtractRegionOfInterestInOneImage/Documentation.html](https://itk.org/ITKExamples/src/Filtering/ImageGrid/ExtractRegionOfInterestInOneImage/Documentation.html) However, I’m having difficulties using this function in Python. I’ve tried writing the code this way, without success: image\_slice11 = itk.region\_of\_interest\_filter(image, [512,512,1], [0,0,11]) Can you provide advice on how that should be implemented? B…

---

_[View the full topic](https://discourse.itk.org/t/slice-3d-volume-along-a-specific-axis-using-python-itk/6005)._
