# Image format for exercise 1.7 Extracting Slices

**URL:** <https://discourse.itk.org/t/image-format-for-exercise-1-7-extracting-slices/4085>\
**Category:** Beginner Questions\
**Created:** [May 1, 2021, 8:30am UTC](https://discourse.itk.org/t/image-format-for-exercise-1-7-extracting-slices/4085 "2021-05-01T08:30:52Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![rohit\_inippully](https://discourse.itk.org/user_avatar/discourse.itk.org/rohit_inippully/32/2056_2.png) [@rohit\_inippully](https://discourse.itk.org/u/rohit_inippully)\
**Post date:** [May 1, 2021, 8:30am UTC](https://discourse.itk.org/t/image-format-for-exercise-1-7-extracting-slices/4085/1 "2021-05-01T08:30:53Z")

</div>

Hi,  
I am going through the guide for ITK. I am not sure which image file format I need to use for exercise 1.7 to extract a slice. Could anyone please advise?

thank you.

---

<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:** [May 3, 2021, 5:50pm UTC](https://discourse.itk.org/t/image-format-for-exercise-1-7-extracting-slices/4085/2 "2021-05-03T17:50:36Z")

</div>

Can you provide a link to the material you are going through?

---

<div class="post-metadata">

**Author:** ![rohit\_inippully](https://discourse.itk.org/user_avatar/discourse.itk.org/rohit_inippully/32/2056_2.png) [@rohit\_inippully](https://discourse.itk.org/u/rohit_inippully)\
**Post date:** [May 14, 2021, 5:57am UTC](https://discourse.itk.org/t/image-format-for-exercise-1-7-extracting-slices/4085/3 "2021-05-14T05:57:35Z")

</div>

Hey dzenanz,  
Thanks for your reply. I used a nifti image for this exercise.  
And I am using the software guide (book2)  
[https://itk.org/ItkSoftwareGuide.pdf](https://itk.org/ItkSoftwareGuide.pdf)  
Thank you.

---

<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:** [May 14, 2021, 2:28pm UTC](https://discourse.itk.org/t/image-format-for-exercise-1-7-extracting-slices/4085/4 "2021-05-14T14:28:56Z")

</div>

You should be able to use any file format, including nifti. But the third command line argument (slicer number) is required, and [PR 2532](https://github.com/InsightSoftwareConsortium/ITK/pull/2532) enforces that.

If you already used 3 arguments, can you share how you invoke the example, and dimensions of your input image?
