# RegionOfInterestImageFilter to extract image slice from volume

**URL:** <https://discourse.itk.org/t/regionofinterestimagefilter-to-extract-image-slice-from-volume/4787>\
**Category:** Beginner Questions\
**Tags:** itk, python\
**Created:** [February 7, 2022, 11:21am UTC](https://discourse.itk.org/t/regionofinterestimagefilter-to-extract-image-slice-from-volume/4787 "2022-02-07T11:21:58Z")\
**Posts on this page:** 1\
**Showing post:** 6

<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:** [February 14, 2022, 10:04pm UTC](https://discourse.itk.org/t/regionofinterestimagefilter-to-extract-image-slice-from-volume/4787/6 "2022-02-14T22:04:25Z")

</div>

Another option to be aware of: a) use `itk.xarray_from_image`, b) do the slicing with pandas/numpy syntax, c) then `itk.image_from_xarray`. This may be more convenient while preserving spatial metadata.

---

_[View the full topic](https://discourse.itk.org/t/regionofinterestimagefilter-to-extract-image-slice-from-volume/4787)._
