# Elastix extension not creating a transform

**URL:** <https://discourse.slicer.org/t/elastix-extension-not-creating-a-transform/4896>\
**Category:** Support\
**Tags:** registration, elastix\
**Created:** [November 27, 2018, 9:09pm UTC](https://discourse.slicer.org/t/elastix-extension-not-creating-a-transform/4896 "2018-11-27T21:09:37Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![stephan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/stephan/32/2444_2.png) [@stephan](https://discourse.slicer.org/u/stephan)\
**Post date:** [November 27, 2018, 9:09pm UTC](https://discourse.slicer.org/t/elastix-extension-not-creating-a-transform/4896/1 "2018-11-27T21:09:37Z")

</div>

System: Win 7 64 bit, Slicer 4.10.0, SlicerElastix extension  
Expected behavior: Save Elastix results in transformation  
Actual behavior: Transformation is still identity (Linear transform, diag (1,1,1,1)) after running Elastix.

Hi @lassoan and everybody,

I tried out the Elastix registration extension today but it does not return a registration.  
I selected my **moving and fixed volume** (both contrast-enhanced cardiac CTs of a pig at different time-points, differing in size but otherwise similar) and an **output transform** (which I created using Create New Transform as… from the output transform drop-down menu).  
The **parameter set** I selected is “3D CT monomodal (lung)”.  
I then run Elastix by clicking “Apply”. Elastix runs for almost 1 hour and gives the following output:

```
Volume registration is started in working directory: C:/Users/M171189/AppData/Local/Temp/Slicer/Elastix/20181127_135854_439
Register volumes...
Generate output...
Error:

```

The working directory contains the following files:

```
\input
    fixed.mha
    moving.mha

\result-transform
    elastix.log

    IterationInfo.0.R0.txt 
    ...
    IterationInfo.2.R4.txt

    TransformParameters.0.R0.txt
    ...
    TransformParameters.2.R4.txt

    result.0.mhd 
    result.0.raw

```

However, the transformation newer shows up in Slicer (the output transformation is empty and the “Information” panel in the Transform module states “Transform to parent: Not specified”)

The log file is huge and contains a couple of warnings, but no errors as far as I can see.

As this is my first attempt to use Elastix, I unfortunately have no clue what else I could try.  
Any hints and suggestions are appreciated.

Thank you  
Stephan

---

<div class="post-metadata">

**Author:** ![cpinter](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/cpinter/32/7995_2.png) [@cpinter](https://discourse.slicer.org/u/cpinter)\
**Post date:** [November 27, 2018, 11:00pm UTC](https://discourse.slicer.org/t/elastix-extension-not-creating-a-transform/4896/2 "2018-11-27T23:00:25Z")

</div>

Is it possible that you did not specify an output volume? Unfortunately computation fails if only an output transform is given but no volume.

I fell into that trap a while ago and reported it as a bug: [https://github.com/lassoan/SlicerElastix/issues/9](https://github.com/lassoan/SlicerElastix/issues/9)

---

<div class="post-metadata">

**Author:** ![brhoom](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/brhoom/32/1228_2.png) [@brhoom](https://discourse.slicer.org/u/brhoom)\
**Post date:** [November 27, 2018, 11:14pm UTC](https://discourse.slicer.org/t/elastix-extension-not-creating-a-transform/4896/3 "2018-11-27T23:14:29Z")

</div>

> I unfortunately have no clue what else I could try.  
> Any hints and suggestions are appreciated.

what about sharing the huge log file?

---

<div class="post-metadata">

**Author:** ![stephan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/stephan/32/2444_2.png) [@stephan](https://discourse.slicer.org/u/stephan)\
**Post date:** [November 28, 2018, 12:19am UTC](https://discourse.slicer.org/t/elastix-extension-not-creating-a-transform/4896/4 "2018-11-28T00:19:17Z")

</div>

You are right, I did not specify an output volume, only a transform. I’ll retry with specifying both tomorrow when I’m back in the office, but it looks like that might have been the problem.  
Thank you very much.

---

<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:** [November 28, 2018, 5:20am UTC](https://discourse.slicer.org/t/elastix-extension-not-creating-a-transform/4896/5 "2018-11-28T05:20:38Z")

</div>

I’ve fixed the [issue](https://github.com/lassoan/SlicerElastix/issues/9). If you update SlicerElastix tomorrow or later then you can run the registration without selecting an output volume.
