VMTK Slicer extension code

This is primarily addressed to Andras @lassoan, since it appears you’re the author of the SlicerExtension-VMTK code:

I’ve been trying to use some parts of the CenterlineComputation.py code, and there are some things that confuse me. What I’d like to do is create a manual vessel segmentation for a single non-branching artery, create a surface model for it, and calculate a centreline for the full length of the model. Below is an image of the artery surface model.
So, I know where I would like to start and end the centreline, and it’s in the middle of the vessel at the Superior and Inferior ends. I’m confused by how CenterlineComputation.py is set up though. At least for extractNetwork, it appears that the source point is one from the wall of the vessel model, and openSurfaceAtPoint is used to isolate the source point from any cells. Am I understanding this correctly?
Could you explain how the source and target points for computeCenterlines are chosen?
If I know where I want the source and target to be, but there aren’t points already there, can I add points to the model and set those as the source and target?
Thanks in advance for your help.

artery-model

Unfortunately VMTK does not have any API documentation. So, the only ways to find out how things work is to read VMTK code or ask on VMTK mailing list.

For simple centerline extraction, you can use Extract skeleton module in recent nightly builds, choose to save centerline points as Output markup fiducials. You may need to enable “Do not prune branches”. Input image is a labelmap. If you have your vessel as a segment then you have to export it to a labelmap node using Segmentations module.

1 Like

Thanks for your reply. I’ll have a look at these, and see what I can figure out. Thanks also for the link to the VMTK mailing list.