# Keep position and orientation of segmentation when saving

**URL:** <https://discourse.slicer.org/t/keep-position-and-orientation-of-segmentation-when-saving/963>\
**Category:** Support\
**Tags:** segmentation, transforms\
**Created:** [August 29, 2017, 1:36pm UTC](https://discourse.slicer.org/t/keep-position-and-orientation-of-segmentation-when-saving/963 "2017-08-29T13:36:50Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![amewes](https://avatars.discourse-cdn.com/v4/letter/a/f475e1/32.png) [@amewes](https://discourse.slicer.org/u/amewes)\
**Post date:** [August 29, 2017, 1:36pm UTC](https://discourse.slicer.org/t/keep-position-and-orientation-of-segmentation-when-saving/963/1 "2017-08-29T13:36:50Z")

</div>

Operating system: Win 10  
Slicer version: Current Nightly  
Expected behavior: surface model from segmentation should be in correct position with respect to volume  
Actual behavior: surface model from segmentation is shifted somewhere

I want to segment a rib from a dataset and save it as a ply file. However, the exported model is not at the correct position but shifted somewhere. How do I keep the transform of the anatomical dataset so that the segmented model remains at the correct position? I would expect this to be the default behaviour.

---

<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:** [August 29, 2017, 1:42pm UTC](https://discourse.slicer.org/t/keep-position-and-orientation-of-segmentation-when-saving/963/2 "2017-08-29T13:42:30Z")

</div>

Does the exported model appear in the correct position in Slicer?  
If you save the model to file and load it back to Slicer, does the exported model appear in the correct position?  
Have you applied a transform on your Segmentation node?  
Do you have this alignment problem when you load the surface mesh and volume in some other software?

---

<div class="post-metadata">

**Author:** ![amewes](https://avatars.discourse-cdn.com/v4/letter/a/f475e1/32.png) [@amewes](https://discourse.slicer.org/u/amewes)\
**Post date:** [August 30, 2017, 9:21am UTC](https://discourse.slicer.org/t/keep-position-and-orientation-of-segmentation-when-saving/963/3 "2017-08-30T09:21:15Z")

</div>

It appears at the correct position in slicer, but not in external programs (Meshlab).  
I did not apply any transform to it.

When I export the segmented model as a labelmap, import the label map in an other program (MeVisLab), and export it as ply, then it has the correct position.

It seems that I cannot choose a reference volume in model export in slicer; this is possible only for labelmap export. Maybe that’s why it is positioned at origin coordinates?

---

<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:** [August 30, 2017, 11:23am UTC](https://discourse.slicer.org/t/keep-position-and-orientation-of-segmentation-when-saving/963/4 "2017-08-30T11:23:13Z")

</div>

STL files cannot store in a standard way what unit and coordinate system is used and each software use different conventions. Following the solution described in this topic will most likely resolve the inconsistency for you:

[https://discourse.slicer.org/t/misalignment-visualization-problem/821/2](https://discourse.slicer.org/t/misalignment-visualization-problem/821/2)
