find cli-modules path

FiberTractMeasurementsCLI = “/Applications/”
This is the path I need to use in the later code, but for other users, the path changes depends on the version of the Slicer they installed. So I use a command:
FiberTractMeasurementsCLI = glob.glob(“/SlicerDMRI/lib//cli-modules/FiberTractMeasurements”, recursive=True)[0] to search the path in the computer, but it takes too long time to find. I wonder if there are any command in Slicer which can find the path of the module installed.
By the way, the module is contained in DMRI.
Best wishes,

I don’t have DMRI installed on this machine, but since the module you are running is a CLI, you should be able to do something like this:

>>> slicer.modules.modelmaker.path

Replace modelmaker with fibertractmeasurements.