Difference between revisions of "Slicer3:Chain CLMs"

From NAMIC Wiki
Jump to: navigation, search
Line 83: Line 83:
 
** The generation of the appropriate CLM descriptor by tweaking the CLM descriptors of its aggregated CLMs.
 
** The generation of the appropriate CLM descriptor by tweaking the CLM descriptors of its aggregated CLMs.
 
** The sequential invocation of the aggregated CLMs with a deterministic argument replacement policy (described by the "argument" elements of the "Chain Descriptor").
 
** The sequential invocation of the aggregated CLMs with a deterministic argument replacement policy (described by the "argument" elements of the "Chain Descriptor").
 +
 +
== Jim's notes ==
  
 
= Key Investigators =
 
= Key Investigators =

Revision as of 13:54, 31 March 2008

Home < Slicer3:Chain CLMs

Chain CLMs

Goals

  • Create an infrastructure for Slicer3 that allows the user to create custom CLMs capable of executing a subset of predefined CLMs in a predefined sequential order.
  • These custom CLMs must be capable to apply a user-defined argument replacement policy, before invoking a CLM. In essence the values of predefined outputs of some aggregated CLMs will be passed as inputs to other predefined aggregated CLMs (with a higher sequential execution order).

Description

The following is a design of an infrastructure to provide basic CLM chaining capabilities in Slicer3.

Generic Chain CLM Application

  • The generic chain CLM application is the engine of the infrastructure.
  • This application takes all information regarding how to chain a list of CLM modules and carries on such tasks when required.
  • Chaining a list of CLM modules is done by proxying to them in order to create an appropriate composite CLM descriptor and to execute the aggregated CLMs in the custom pre-configured way.
  • A particular "Chain CLM" will be a script which internally:
    • Invokes this generic application.
    • Configures it with a specific fixed "Chain Descriptor".
  • A particular "Chain CLM" script (X-ChainCLM.sh) will look like:
#!/bin/sh
java -cp slicerCLMPs.jar ChainCLMApp X-Modules.xml

where "X-Modules.xml" is the "Chain Descriptor" that shall be used to determine how to sequentially execute and chain the results and arguments of an ordered list of CLMs.

Chain Descriptor

  • This is an XML file which contains all the information necessary to deterministically proxy into CLMs and "chain them".
  • It must conform to the following schema:
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:clm="http://www.na-mic.org/clm" targetNamespace="http://www.na-mic.org/clm" elementFormDefault="qualified">
   <xs:element name="modules">
      <xs:complexType>
          <xs:sequence>
             <xs:element name="module" type="clm:module" minOccurs="2" maxOccurs="unbounded"/>
          </xs:sequence>
      </xs:complexType>
   </xs:element>
   <xs:complexType name="module">
      <xs:sequence>
          <xs:element name="argument" type="clm:argument" minOccurs="0" maxOccurs="unbounded"/>
      </xs:sequence>
      <xs:attribute name="id" type="xs:string"/>
   </xs:complexType>
   <xs:complexType name="argument">
      <xs:attribute name="name" type="xs:string"/>
      <xs:attribute name="value-ref" type="xs:string"/>
   </xs:complexType>
</xs:schema>
  • "Chain Descriptor" example 1:
<?xml version="1.0" encoding="UTF-8"?>
<modules xmlns="http://www.na-mic.org/clm" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.na-mic.org/schemas/chainCLM.xsd">
 <module id="Module1"/>
 <module id="Module2">
     <argument name="param2A" value-ref="Module1.param1A" />
     <argument name="param2B" value-ref="Module1.param1B" />
 </module>
 <module id="Module3">
     <argument name="param3C" value-ref="Module1.param1C" />
     <argument name="param3D" value-ref="Module2.param2D" />
 </module>
</modules>

  • "Chain Descriptor" example 2:
<?xml version="1.0" encoding="UTF-8"?>
<modules xmlns="http://www.na-mic.org/clm" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.na-mic.org/schemas/chainCLM.xsd">
  <module id="RicianFilterDWI"/>
  <module id="TensorEstimatorDTI">
      <argument name="inputDWI" value-ref="RicianFilterDWI.outputDWI" />
  </module>
  <module id="DiffusionScalar">
      <argument name="inputDTI" value-ref="TensorEstimatorDTI.outputDiffusionTensorDTI" />
  </module>
</modules>

Internal Functionality

  • Configuring the generic "ChainCLMApp" application with a specific "Chain Descriptor" allows:
    • The generation of the appropriate CLM descriptor by tweaking the CLM descriptors of its aggregated CLMs.
    • The sequential invocation of the aggregated CLMs with a deterministic argument replacement policy (described by the "argument" elements of the "Chain Descriptor").

Jim's notes

Key Investigators

  • UCSD BIRN-CC: Jeffrey Grethe, Marco Ruiz
  • Isomics: Steve Pieper
  • GE: Jim Miller
  • Kitware: Will Schroeder

Links