Load curvenodes from stl/vtk file

Hi,
I am using 3D slicer 4.11.0 for analyzing dental CT. I need a bunch of points around mandible curve to compute a panoramic X-ray from a cone-beam dental CT (https://gist.github.com/lassoan/b445c734f118a5fb7643f3fb05f98b07). I have segmented this curve using “segment editor” -> “draw tube” (to generate the curve from points) -> with fiducial markups (points). This segment can be saved in .vtk or .stl format. From this saved files (vtk or stl) how can I get the points coordinates in python interactor to proceed with my 3D to 2D projection?
Slicer crashes and exists by running this line:
curve = vtk.vtkPolyData(‘path_to/mandible_bow.vtk’)

Do I need to forget about this segmentation (curve in stl/vtk) and save the points in CSV file? If so how should I load points coordinates from it in slicer python interactor?

Any suggestion is appreciated!
Thank you

You can reverse-engineer the curve-shaped segment into a curve using VMTK extension’s brand new “Extract centerline” module - to be released tomorrow for Slicer Preview Release. Give it a try tomorrow and write here if you need help figuring out how to use it.

1 Like

See announcement of the new module here: New module: Extract Centerline (in SlicerVMTK extension)

1 Like