# Slicer/.nrrd Coordinate Systems

**URL:** <https://discourse.slicer.org/t/slicer-nrrd-coordinate-systems/19827>\
**Category:** Support\
**Created:** [September 23, 2021, 3:57pm UTC](https://discourse.slicer.org/t/slicer-nrrd-coordinate-systems/19827 "2021-09-23T15:57:21Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Yoshi888](https://avatars.discourse-cdn.com/v4/letter/y/ec9cab/32.png) [@Yoshi888](https://discourse.slicer.org/u/Yoshi888)\
**Post date:** [September 23, 2021, 3:57pm UTC](https://discourse.slicer.org/t/slicer-nrrd-coordinate-systems/19827/1 "2021-09-23T15:57:21Z")

</div>

Hello everyone,

I am IT student and new to the medical field. I am currently working on Image Processing/Classification Tasks and working with Slicer. I still think I have some understanding issues regarding the Coordinate System used and was hoping you guys could maybe help me.

I currently have data in .nrrd files I work with. From the Header Information I can extract:

‘space’: ‘left-posterior-superior’ → So I can assume my Data is in LPS

‘space directions’:

[5.98936111e-01, 6.15821439e-05, -5.15675320e-03]  
[-1.20481869e-08, 5.98915625e-01, 7.15087395e-03]  
[4.13286886e-02, -5.73043156e-02, 4.79947636e+00]

‘space origin’:

[-115.52378082, -56.22384262, -92.38769531]

So I assume my data is using this system? As Slicer uses RAS it transforms this data from LPS to RAS when viewing it in Slicer?

I would like to rescale all my images to 1 in x, y direction to make them more comparable.  
To do that I just have to apply a corresponding transformation matrix to my data if my understanding is correct?

Overall I am still confused as to what corresponds to what data in which coordinate system.

---

<div class="post-metadata">

**Author:** ![pieper](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/pieper/32/8_2.png) [@pieper](https://discourse.slicer.org/u/pieper)\
**Post date:** [September 23, 2021, 9:02pm UTC](https://discourse.slicer.org/t/slicer-nrrd-coordinate-systems/19827/2 "2021-09-23T21:02:35Z")

</div>

If you haven’t already you should study this page:

[https://www.slicer.org/wiki/Coordinate\_systems](https://www.slicer.org/wiki/Coordinate_systems)

Slicer works internally in RAS but many output formats are LPS implicitly while others are implicitly RAS. Many formats have a flag in the header that says LPS or RAS which we try to respect or you can select the reference when importing files.

---

<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:** [September 24, 2021, 6:10pm UTC](https://discourse.slicer.org/t/slicer-nrrd-coordinate-systems/19827/3 "2021-09-24T18:10:12Z")

</div>

Datasets created by earlier Slicer versions may have used either LPS or RAS coordinate system in files. In recent Slicer releases by default all node types (volumes, models, markups, etc.) are saved in LPS coordinate system.

---

<div class="post-metadata">

**Author:** ![Yoshi888](https://avatars.discourse-cdn.com/v4/letter/y/ec9cab/32.png) [@Yoshi888](https://discourse.slicer.org/u/Yoshi888)\
**Post date:** [September 29, 2021, 7:37am UTC](https://discourse.slicer.org/t/slicer-nrrd-coordinate-systems/19827/4 "2021-09-29T07:37:12Z")

</div>

That Website was indeed very helpful, thank you!

So if I have understood it correctly with the Information from the Header I can transform my Data from IJK to LPS/RAS by applying the matrix.  
’  
I have ADC Maps and T2 Seq and a transformation for registration.

So in my Code I would then have to transform both Images to LPS and then apply the transformation from my registration and then I can transform them back to IJK coordinates so I can proceed with my Image Processing.  
Is that understanding correct?
