# How to Convert MRI nii files into a series of tiff files using 3D Slicer 4.10?

**URL:** <https://discourse.slicer.org/t/how-to-convert-mri-nii-files-into-a-series-of-tiff-files-using-3d-slicer-4-10/10376>\
**Category:** Support\
**Tags:** mri\
**Created:** [February 21, 2020, 4:13am UTC](https://discourse.slicer.org/t/how-to-convert-mri-nii-files-into-a-series-of-tiff-files-using-3d-slicer-4-10/10376 "2020-02-21T04:13:00Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ali\_khattak](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/ali_khattak/32/6103_2.png) [@Ali\_khattak](https://discourse.slicer.org/u/Ali_khattak)\
**Post date:** [February 21, 2020, 4:13am UTC](https://discourse.slicer.org/t/how-to-convert-mri-nii-files-into-a-series-of-tiff-files-using-3d-slicer-4-10/10376/1 "2020-02-21T04:13:00Z")

</div>

Hello all,  
this is my first question in this forum please guide me  
I am using ADNI images for my project of Alzheimer disease detection and classification using CNN but I have 3D images which need high performance GPU and Ultimate performance system so to avoid it I want to convert my each MRI `nii` file into 2D slice (tiff or PNG) files How I will convert through 3D slicer please help me in this regard.  
Thanks in advance.

---

<div class="post-metadata">

**Author:** ![lassoan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lassoan/32/13_2.png) [@lassoan](https://discourse.slicer.org/u/lassoan)\
**Post date:** [February 25, 2020, 12:11am UTC](https://discourse.slicer.org/t/how-to-convert-mri-nii-files-into-a-series-of-tiff-files-using-3d-slicer-4-10/10376/2 "2020-02-25T00:11:51Z")

</div>

I would recommend to convert from scientific (nifti, nrrd, …) to consumer file formats (png, tiff, …) as a temporary workaround (if you want to quickly try a network and don’t want to spend any time with formatting the input data).

To simply write out the native voxel values, you can do this:

```python
pip_install("imageio")
import imageio

voxelArray = slicer.util.arrayFromVolume(myVolumeNode)
for i in range(len(outputLabelmapVolumeArray)):
    imageio.imwrite(f'{outputDir}/image_{i:03}.tiff', outputLabelmapVolumeArray[i])

```

However, probably you would want to normalize the image size, resolution, maybe even intensity values.
