Extract centeline Auto-detect tree mode


I am using the Extact Centerline module with Endpoints Autodetect to generate the centerlines over all the vessels of a coronary tree. For this I use the tree option.
After a couple of attempts and smoothing the geometry I have obtained something like this:

However, I am trying with other patients and I am not able to get all the curves. The program gives me the model but only 1 centreline.

How can i get all centrelines?
The module is very unstable and causes the application to close suddenly on numerous occasions.
I’m using Slicer 5.0.3.

The automatic centerline endpoint detection results are editable. Feel free to move the points to more appropriate locations (for example, move the first point to the center of the aorta, remove the seemingly spurious endpoint slightly above the valve, …). Also make sure the aorta endpoint is marked as inflow (unselected - cyan by default), while others are outflow (selected - red by default).

If all the endpoints are set correctly and the centerline model looks good, but you only get a single curve then it means that topological analysis of the centerline tree failed.

You may try to increase “Target point count” to 10-20k and/or reduce “Decimation aggressiveness” in Advanced section.

No failure should lead to crashing of the application. We haven’t received any reports of VMTK crashing while detecting the centerline, so we are confident that it is robust, but of course there can be always some special cases that may triggered by some unexpected input data. If you can reproduce a crash with the latest stable version (Slicer-5.2) then please upload the input segmentation data somewhere (dropbox, onedrive, etc.) and post the link here so that we can investigate.


I have downloaded the new version of slicer (5.2.1) and the problem persists. For example, for this segmentation with parameters “Target point count” 10k and “Decimation aggressiveness” 3, the program quits unexpectedly.

I don’t know where to change the inflow and outflow parameters for the endpoints. I’ll check if I can upload the example.



Yes, please upload the segmentation and I can have a look.


Unfortunately I can’t upload the geometry at the moment. However, I have noticed that in order to avoid unexpected behaviour it is advisable to smooth the geometry and place the endpoints a bit before the end of the vessels.

I have not yet found where to change the endpoint type (inflow/outflow).

Thanks a lot :slight_smile:

Hi, I experimented the same problem with an aorta in this case.
The geometry is extremely smooth, but Extract Centerline module continues to crash every time, closing Slicer.

What I want is a centerline between the endpoints as shown below

You can find the stl here: Sign in to your account

The crash was due to a bug in VTK that I’ve fixed a couple of months ago, but that fix was not yet backported into Slicer’s VTK. I’ve now backported it, so centerline extraction will work robustly in Slicer Preview Release that you download on 2023-03-19 or later.

Many thanks, so it is not yet available on Windows, right?

The fix is already available in the latest Slicer Preview Releases on all operating systems.

But the last preview release for Windows is from 2023-03-16

There has been an error in the Windows builds. We’ll investigate.

@jcfr could you have a look at this build error on Windows due to generate_pyi.py?

1 Like