Model to Model Distance command line

Hello there!

Me and my teammates are trying to develop a project where we need to apply the model to model distance module with a command line and we were unable to do so.

Is there anyone that knows how to call that module from the terminal?

Thank you in advance!!

What issue are you encountering ?

This would be the command to run the cli from the terminal :

[path_to_the_cli]/ModelToModelDistance.exe -t TargetModel.vtk -s SourceModel.vtk -o OutputModel.vtk -d signed_closest_point

@jhernandezr the ModelToModelDistance modle is a command-line module, which can be called from command line directly as @rfenioux suggests. The module requires though the use of some other libraries that won’t be found unless some Slicer environment variables are set. For me, invoking the module through Slicer --launch worked fine:

./Slicer --launch slicer.org/Extensions-32438/ModelToModelDistance/lib/Slicer-5.6/cli-modules/ModelToModelDistance -s /tmp/m1.vtk -t /tmp/m2.vtk -o /tmp/output.vtk
1 Like