<div dir="ltr">Hey Matt, that's a handy way to find sample code, thanks very much.<div><br><div style>I modified itkTimeVaryingBSplineVelocityFieldImageRegistrationTest very slightly to be able to run it outside the ITK testing framework (just renaming the function "itkTimeVaryingBSplineVelocityFieldImageRegistrationTest" to "main" was sufficient). I'm having it register two 3D images and it's currently taking over 14 GB's of memory! (though thankfully it is continuing to run without anything horrible happening). Is this normal? I am using all the default parameters:</div>
</div><div style>learningRate: 0.5</div><div style>iterations per level: 10, 20, 11</div><div style><br></div><div style>Each image is quite large, 320x320x160 array of short ints. I guess as long as it finishes, I can't really complain. Still though, it doesn't seem normal to be using so much memory. Perhaps I've done something horribly wrong?</div>
<div style><br></div><div style>Thanks,</div><div style>andrew</div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, May 7, 2013 at 7:48 AM, Matt McCormick <span dir="ltr"><<a href="mailto:matt.mccormick@kitware.com" target="_blank">matt.mccormick@kitware.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Andrew (CC'ing the mailing list -- please remember to reply-to-all),<br>
<br>
The tests for the class are also a useful reference. To see the tests,<br>
<br>
ctest -R TimeVarying -N<br>
<br>
which yields:<br>
<br>
<br>
Test #478: itkTimeVaryingVelocityFieldTransformTest<br>
Test #479: itkTimeVaryingVelocityFieldIntegrationImageFilterTest<br>
Test #480: itkTimeVaryingBSplineVelocityFieldTransformTest<br>
Test #1782: itkTimeVaryingVelocityFieldImageRegistrationTest<br>
Test #1783: itkTimeVaryingBSplineVelocityFieldImageRegistrationTest<br>
<br>
The code for the tests can be found in<br>
Modules/Registration/RegistrationMethodsv4/test/<br>
<br>
HTH,<br>
Matt<br>
<div class="HOEnZb"><div class="h5"><br>
On Mon, May 6, 2013 at 7:56 PM, Andrew Ho <<a href="mailto:andrewkennethho@gmail.com">andrewkennethho@gmail.com</a>> wrote:<br>
> Hey Matt,<br>
> Thanks for the pointer, it sounds like this might be just what I need. Is<br>
> there any documentation, examples, or papers for this method (or class of<br>
> methods) beyond the doxygen generated ones?<br>
><br>
> Also, are there any limitations on the metric and optimizer which can be<br>
> used with this method? Sorry if these are dumb questions, I'm really new to<br>
> ITK and image registration in general.<br>
><br>
> Thanks,<br>
> andrew<br>
><br>
><br>
> On Mon, May 6, 2013 at 10:28 AM, Matt McCormick <<a href="mailto:matt.mccormick@kitware.com">matt.mccormick@kitware.com</a>><br>
> wrote:<br>
>><br>
>> Hi Andrew,<br>
>><br>
>> You may find this class useful:<br>
>><br>
>><br>
>> <a href="http://www.itk.org/Doxygen/html/classitk_1_1TimeVaryingVelocityFieldImageRegistrationMethodv4.html" target="_blank">http://www.itk.org/Doxygen/html/classitk_1_1TimeVaryingVelocityFieldImageRegistrationMethodv4.html</a><br>
>><br>
>> HTH,<br>
>> Matt<br>
>><br>
>> On Fri, Apr 26, 2013 at 7:29 PM, Andrew Ho <<a href="mailto:andrewkennethho@gmail.com">andrewkennethho@gmail.com</a>><br>
>> wrote:<br>
>> > Hi there,<br>
>> > I'm wondering if there is a suitable set of tools in ITK for my purpose:<br>
>> ><br>
>> > I have high-resolution 4D CT data of the human upper airway during<br>
>> > swallowing. I'd like segment the upper airway and use it as the moving<br>
>> > boundaries in a physics simulation. The dataset is large, but it's not<br>
>> > too<br>
>> > much to ask to manually segment it (frame by frame). The problem is that<br>
>> > some interpolation is required in time. For this, it seems like a good<br>
>> > approach would be to register sequential time frames and use the<br>
>> > resulting<br>
>> > deformation field to move a mesh. Then interpolation can be performed on<br>
>> > the<br>
>> > deformation field in order to advance the airway structure in time.<br>
>> ><br>
>> > There are a few approaches that I am considering, some of which I<br>
>> > gleaned<br>
>> > from searching the mailing list:<br>
>> ><br>
>> > 1) Perform 3D deformable registration between time frames (using the raw<br>
>> > image data) and acquire deformation fields. Use the deformation field to<br>
>> > move a mesh which is segmented from the first time frame. -- The problem<br>
>> > here is that the registration problem is difficult because of the<br>
>> > rapidly<br>
>> > moving bolus (the fluid being swallowed). There is also poor contrast<br>
>> > between some structures as they close the airway during the sequence.<br>
>> ><br>
>> > 2) Perform 3D manual segmentation on two sequential frames. Generate<br>
>> > meshes<br>
>> > from the segmented surfaces and register these two meshes. Use the<br>
>> > resulting<br>
>> > deformation field to move one mesh to the next time frame. -- The<br>
>> > problem<br>
>> > here (not really a problem) is that I don't know if a mesh to mesh<br>
>> > registration (such as ICP) can be used to generate a deformable field.<br>
>> ><br>
>> > 3) Perform manual segmentation of the airway in frame 1 and use it as<br>
>> > input<br>
>> > to a simplex registration method on frame 2 (suggested here, way back in<br>
>> > 2004:<br>
>> > <a href="http://www.itk.org/pipermail/insight-users/2004-November/011080.html" target="_blank">http://www.itk.org/pipermail/insight-users/2004-November/011080.html</a>)<br>
>> > -- The problem here is that I'm not sure if the segmentation will be<br>
>> > able to<br>
>> > handle the low-contrast areas when closure occurs. Another problem<br>
>> > (again,<br>
>> > not really a problem) is that the files seem to have changed and I'm not<br>
>> > sure if the listed examples are still relevant<br>
>> ><br>
>> > Any suggestions and insight (sorry for that) would be much appreciated!<br>
>> ><br>
>> > Thanks,<br>
>> > andrew<br>
>> ><br>
>> > _____________________________________<br>
>> > Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
>> ><br>
>> > Visit other Kitware open-source projects at<br>
>> > <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
>> ><br>
>> > Kitware offers ITK Training Courses, for more information visit:<br>
>> > <a href="http://www.kitware.com/products/protraining.php" target="_blank">http://www.kitware.com/products/protraining.php</a><br>
>> ><br>
>> > Please keep messages on-topic and check the ITK FAQ at:<br>
>> > <a href="http://www.itk.org/Wiki/ITK_FAQ" target="_blank">http://www.itk.org/Wiki/ITK_FAQ</a><br>
>> ><br>
>> > Follow this link to subscribe/unsubscribe:<br>
>> > <a href="http://www.itk.org/mailman/listinfo/insight-users" target="_blank">http://www.itk.org/mailman/listinfo/insight-users</a><br>
>> ><br>
><br>
><br>
</div></div></blockquote></div><br></div>