AIM-Harvard / SlicerRadiomics

A Slicer extension to provide a GUI around pyradiomics
BSD 3-Clause "New" or "Revised" License
106 stars 48 forks source link

Impove Slicer CLI #38

Closed jcfr closed 6 years ago

jcfr commented 6 years ago

Copied from https://github.com/Radiomics/SlicerRadiomics/pull/37

JoostJM commented 6 years ago

Progress reporting is still fairly basic now, it returns the logger output of PyRadiomics and shows some dots accumulating during the extraction.

pieper commented 6 years ago

Making the CLI module hidden has been on the wish list before [1]. None of the solutions in that thread are very satisfactory (e.g. putting the CLI in an "Advanced" category). Even the ugly workaround of removing it from the module menu doesn't work because it still shows up when searching for modules with Control-F.

Probably the best answer would be to add some hint in the xml file and extend the SlicerExecutionModel and the corresponding code in Slicer to respect that flag. A scripted or loadable module in Slicer can set a 'hidden' property but CLIs cannot currently.

I'm not seeing any other convenient way to hide the CLI. Suggestions?

[1] http://slicer-devel-archive.65872.n3.nabble.com/Hiding-CLI-from-Slicer-user-interface-td4038452.html#a4038457

jcfr commented 6 years ago

Probably the best answer would be to add some hint in the xml file

Generally speaking, I don't think CLI should dictate if there are visible or not for the user. This is application specific.

Instead, we could:

pieper commented 6 years ago

Generally speaking, I don't think CLI should dictate if there are visible or not for the user. This is application specific. That's a good point.

An application setting for which modules to hide could be good.

Another option might be to have a new directory, perhaps called cli-logic-modules or cli-hidden-modules, next to the cli-modules for any clis that the extension would like to have hidden. Then we would just need to handle that case in the module discovery process.

fedorov commented 6 years ago

IMHO and all things considered, I am not convinced focusing on how to hide a CLI is a high enough priority to justify the effort.

Hiding this one CLI will not make Slicer automagically less confusing, and there is nothing illegitimate in having the "raw" CLI interface. As long as the users know that Radiomics is the main gateway for the analysis, it should be ok. If they start wandering around in the module list, and they don't know what they are doing, they will be lost, and it will not be because of this one CLI.

jcfr commented 6 years ago

I am not convinced focusing on how to hide a CLI is a high enough priority to justify the effort

Makes sense

Another option might be to have a new directory, perhaps called cli-logic-modules or cli-hidden-modules

That would work, but the name of directory currently doesn't enforce any behavior. I am not sure this is the right level of abstraction.

JoostJM commented 6 years ago

I am not convinced focusing on how to hide a CLI is a high enough priority to justify the effort

I agree, the CLI is works fine in a stand-alone mode too