# TubeTK hepatic vessel registration workflow

**URL:** <https://discourse.itk.org/t/tubetk-hepatic-vessel-registration-workflow/3294>\
**Category:** Algorithms\
**Created:** [July 16, 2020, 7:54pm UTC](https://discourse.itk.org/t/tubetk-hepatic-vessel-registration-workflow/3294 "2020-07-16T19:54:34Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Henco](https://discourse.itk.org/letter_avatar_proxy/v4/letter/h/cab0a1/32.png) [@Henco](https://discourse.itk.org/u/Henco)\
**Post date:** [July 16, 2020, 7:54pm UTC](https://discourse.itk.org/t/tubetk-hepatic-vessel-registration-workflow/3294/1 "2020-07-16T19:54:34Z")

</div>

Hello all,

I recently read the [Alward et al. paper](http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.98.8875&rep=rep1&type=pdf) on their unique way of registering blood vessels to DSAs. I’d like to implement it an ITK project and I found that group had created TubeTK. I’d like use TubeTK to register hepatic blood vessels to DSAs, but I can’t find an example of a workflow to follow. In other words, I’m not sure which of their ITK modules to use

---

<div class="post-metadata">

**Author:** ![matt.mccormick](https://discourse.itk.org/user_avatar/discourse.itk.org/matt.mccormick/32/7_2.png) [@matt.mccormick](https://discourse.itk.org/u/matt.mccormick)\
**Post date:** [July 16, 2020, 9:04pm UTC](https://discourse.itk.org/t/tubetk-hepatic-vessel-registration-workflow/3294/2 "2020-07-16T21:04:48Z")

</div>

Ping @Stephen_Aylward

---

<div class="post-metadata">

**Author:** ![Henco](https://discourse.itk.org/letter_avatar_proxy/v4/letter/h/cab0a1/32.png) [@Henco](https://discourse.itk.org/u/Henco)\
**Post date:** [July 17, 2020, 4:01am UTC](https://discourse.itk.org/t/tubetk-hepatic-vessel-registration-workflow/3294/3 "2020-07-17T04:01:01Z")

</div>

@Stephen_Aylward  
Good evening, I was hoping to use TubeTK to emulate the work that you did in your paper _Registration and Analysis of Vascular Images_, but I’m running into several problems. I tried following the instructions [here](https://github.com/InsightSoftwareConsortium/ITKTubeTK) to use TubeTK as a module of ITK. I have followed the instructions under the heading [CompilingITKTubeTK: an ITK remote module!!!](https://github.com/InsightSoftwareConsortium/ITKTubeTK#compiling-itktubetk-an-itk-remote-module). I’m able to successfully compile and build ITK with TubeTK at this point.  
My issue occurs [here](https://github.com/InsightSoftwareConsortium/ITKTubeTK#using-a-compiled-and-python-wrapped-itk-and-itktubetk-from-python), when trying to accomplish the second portion of the task where it asks me to copy ITK’s and ITKTubeTK’s paths file into the site-packages directory. I’m having a problem with TubeTK’s path. I am unable to find the WrapITK.pth that is supposed to be in TubeTK’s directory. There is no Generators directory, or anything downstream of it.  
I also noticed that in the wiki, it refers to ITKTubeTK as if it is built outside of the ITK build tree. But when I attempt to configure it, I receive the following cmake error:  
`CMake Error at C:/Users/henry/ITK/ITK-master/CMake/ITKModuleMacros.cmake:472 (add_library): add_library cannot create target "TubeTK" because an imported target with the same name already exists. Call Stack (most recent call first): src/CMakeLists.txt:37 (itk_module_add_library)`  
So I’m a little confused, as the first step is to build ITK with TubeTK enabled, but that blocks the ITKTubeTK out-of-source build later on.

---

<div class="post-metadata">

**Author:** ![Stephen\_Aylward](https://discourse.itk.org/user_avatar/discourse.itk.org/stephen_aylward/32/654_2.png) [@Stephen\_Aylward](https://discourse.itk.org/u/Stephen_Aylward)\
**Post date:** [July 17, 2020, 2:58pm UTC](https://discourse.itk.org/t/tubetk-hepatic-vessel-registration-workflow/3294/4 "2020-07-17T14:58:38Z")

</div>

Hi Henco,

You only need to compile ITK. You never need to checkout or compile TubeTK. I will try to make that clearer in the instructions.

When configuring ITK, simple set the following cmake variables:

- CMAKE\_BUILD\_TYPE = Release
- ITK\_WRAP\_PYTHON = On
- Module\_TubeTK = On

Also, if you don’t want to compile ITK, you can instead simply do

- pip install itk-tubetk

Hope this helps, and I apologize for the out of date documentation.

s

---

<div class="post-metadata">

**Author:** ![Henco](https://discourse.itk.org/letter_avatar_proxy/v4/letter/h/cab0a1/32.png) [@Henco](https://discourse.itk.org/u/Henco)\
**Post date:** [July 23, 2020, 8:24pm UTC](https://discourse.itk.org/t/tubetk-hepatic-vessel-registration-workflow/3294/6 "2020-07-23T20:24:52Z")

</div>

@Stephen_Aylward  
Thank you for the help, I did manage to properly install TubeTK for use with python.  
I still have a question regarding the framework you used to register a CT model to X-ray images in your group’s research paper “[3D/2D Model-to-Image Registration Applied to TIPS Surgery](https://link.springer.com/content/pdf/10.1007/11866763_81.pdf)”.  
Is it possible to use TubeTK/src/Registration/itktubeImageToTubeRigidRegistration.h to register 3D/2D?
