1 / 12

Slicer4 CLI

Slicer4 CLI. Slicer Execution Model. Variety of levels of integration. What is a CLI Module?. Simplest mechanism to contribute an algorithm to Slicer Plugin mechanism Command line paradigm Plugins are called with (argc, argv)

sitara
Download Presentation

Slicer4 CLI

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Slicer4 CLI Slicer Execution Model

  2. Variety of levels of integration

  3. What is a CLI Module? • Simplest mechanism to contribute an algorithm to Slicer • Plugin mechanism • Command line paradigm • Plugins are called with (argc, argv) • Arguments are flags, flags with values, or just indexed on the command line • CLI modules are self describing • ./myplugin –xml • Produces an XML description of the parameters for the plugin • CLI modules can be executables, shared libraries, or scripts • CLI modules can be used within Slicer or in batch

  4. XML description of a module…

  5. … produces a user interface

  6. … produces command line parsing code

  7. MRML magic If built as a shared library, these calls will pull data directly from the MRML scene!

  8. Inside Slicer… Slicer provided Module writer provided vtkMRMLCommandLineModuleNode qSlicerCLIModuleWidget vtkSlicerCLIModuleLogic • YourModule.xml • <image> • <geometry> • <integer> • <double> • <file> qSlicerCLIModuleUIHelper • YourModule.py • XML • def toXML() • def Execute() • YourModule (exe) • YourModule –xml • YourModule.so • XMLModuleDescription • GetXMLModuleDescription() • ModelEntryPoint() or or

  9. CLI Build System (within Slicer tree) One CLI, one directory CMakeList.txt

  10. CLI Build System (as Slicer Extension)

  11. What can SEM/CLI do today? • Modules can be executables, shared libraries, scripts • Module “interface” defined through parameters • Parameters include “simple” and “bulk” types • Parameters passed through command line and files • Modules can be run inside and outside of 3D Slicer • Modules can report progress • Modules can be aborted • Modules are run in a separate processing thread • User interface built automatically from the parameter descriptions • Modules can be re-used easily from Python, harder to re-use in C++

  12. What CAN’T SEM/CLI do today • Pass back intermediate results • Update the 3D Visualization/Slice Viewers while executing • Accept input while running to steer the module • Request input while running • Automatically execute with changes in MRML • Orchestrate a change in layout or visualization content • Easily use collections of Modules in a workflow or wizard • Call a SEM/CLI from a SEM/CLI

More Related