Projects:ARRA:SlicerWF:PETCTWorkflowDesign

From NAMIC Wiki
Jump to: navigation, search
Home < Projects:ARRA:SlicerWF:PETCTWorkflowDesign

Documentation

  • User Manual for workflow front-end Java GUI that includes proposed updates:

File:PETCT UserGuide QuickGuide V0.doc
File:VolumeCroppingTutorial PETCT RegistrationProject.ppt

  • Recommended Sessions for Multiple Subjects Processing

File:PETCT RecommendedSessions.doc

  • Calling Workflow instances and web services using Java stub (CLI interface)

NOTE: this is one of the various ways to call WF and Web Services from Slicer
This approach is similar to the XNATRestClient.jar usage
File:PETCT CLI Client Calls V0.pdf

  • Web Services and WF Deployment

File:PETCT WS WF Deployment V0.pdf

July 7, 2010

Alex's workflow (scenario as of discussion during presentation on June 12)

1. Organize inputs:

  USER Activity
  1.1. Select DICOM Series
  1.2 Specify subject ID, time point, image modality
  AUTOMATION:
  1.3 Create Subject folder
  1.4 Convert DICOM series into Slicer NRRD format
  1.5 Save NRRD images in the Subject folder
  1.6 Extract PET pharmaceutical data from DICOM headers. Save them in the Subject folder

2. Crop Volumes

 USER Activity:
 2.1 Select head region for PET/CT scans. For each time point.
 2.2 Save cropped volumes
 Question: do we only crop PET volumes here? Since we don't yet know the reference CT, and don't need to crop CT at each timepoint.

3. Create ROI Label Map

 USER Activity:
 3.1 Use Timepoint 1 cropped PET scan (AZ: technically, any PET scan can be selected for ROI label map building)
 AUTOMATION:
 3.2 Create blank label map that matches PET
 USER Activity:
 3.3. Identify ROI using custom color label lookup table (Slicer3 Feature)
 3.4. Save ROI Label

4. Identify reference CT scan

 USER Activity:
 4.1. Point to appropriate CT volume
 4.2. [Optional] Manual alignment of reference CT volume
 4.3  [If 4.2 performed] Save Aligned CT volume

5. Launch Registration Pipeline

AUTOMATION:
5.1 For each timepoint, register PET scan to CT scan
5.2 For timepoint 1, safe transformation matrix from 5.1
5.3 For each timepoint, register CT scan to reference CT scan
5.4 For each timepoint, safe transformation  matrix  from  5.3.
5.5  For each timepoint, registered PET scans using transformation matrix from 5.4.
5.6 Resample ROI label map the reference CT using transformation matrixes from 5.2 and 5.4
5.7 Generate result review scenes descriptor files

6. Compute SUVs

AUTOMATION:
6.1 Merge PET pharmaceutical data with registered PET images' headers
6.2 Compute SUVs. Save results in CSV format in the Subject folder

7. Results Preview:

USER Activity
7.1 Load results' sets along with resampled RIO label map via Slicer scene files.
7.2 (TBD) Build time series intensity plots

workflow proposed by Ron

Pending Updates:
1. Hierarchical File Organizing
2. Slice Comparison View for QA and Results Review
3. Complete SUV computation services


(First)

  • tech (or we) organize data (maybe as described at bottom)

(Second)

  • tech launches workflow engine GUI with root data dir as argument
    • (code parses data dir to produce selectable items)
  • tech chooses a patient by ID and chooses timepoint by number.
    • code converts dcm->nrrd,
    • extracts dcm headers and
    • saves file into appropriate dir, (all under the hood)
    • tech is shown choose registration reference stepby default
    • clicks go & slicer is launched with all CT scans for patient.
  • tech chooses a ct reference by timepoint in workflow engine GUI.
    • this clears Slicer scene and
    • loads all pets plus ct reference into slicer
  • tech crops all volumes for patient and manually saves them
  • tech runs registration
    • code checks to make sure all crop volumes are written.
    • registers pet_i to pet_ref, -->pet_i',
    • then pet_i' to ct_ref --> pet_i,
    • saves results into directory tree appropriately.

(Third -- QA)

  • if not already running, tech launches workflow engine GUI with root data dir as argument
  • selects patient.
  • selects preview registration
    • slicer launches or scene is closed in existing slicer;
    • opens all cropped, registered volumes for patient
  • tech reviews, if not good, goes back to choose reference step and repeat registration.

(Forth)

  • laura launches workflow engine GUI with root data dir as argument.
  • code parses data dir to produce selectable items)
  • laura chooses a patient by ID and then drawVOI step.
    • slicer is launched or scene is closed in an existing slicer;
    • pet baseline is loaded,
    • label map is created, and
    • her color map is selected.
  • she paints VOIs using editor, saves label map.
  • repeats for none, some, or all patients.
  • clicks compute SUV step
    • workflow GUI shows all patients in directory who are ready for processing, and
    • shows those that have already been processed.
  • she modifies selection of patients for processing, clicks 'go' for all selected patients.
  • goes home or out for coffee.
    • processing is launched and run
    • results are saved to appropriate dirs

(Fifth Step):

  • later, laura/tech launch workflow engine with root data dir as argument.
  • select single patient or ALL patients for viewing results step
  • view tables & plot.

data organization suggestion

directory structure could be parsed and used to populate the GUI when the GUI client is launched with the root dir as a command line argument.

Then user chooses:

select patient {p_1, p_2, ..., p_N}:
select timepoint {t_1, t_2, ..., t_M}:


Maybe something the directory structure could look something like this, for all patients and timepoints:

input:
./patient_1/input/timepoint_1/pet_orig/petdata.dcm
./patient_1/input/timepoint_1/pet_orig/petdata.nrrd
(tech only needs to know about this. -- the rest of the
structure your logic would use as convention...)
convert:
./patient_1/convert/timepoint_1/ct/ctdata.dcm
./patient_1/convert/timepoint_1/ct/ctdata.nrrd
./patient_1/convert/timepoint_1/parameters/dicomheader.txt
reference:
./patient_1/reference/ct/ctdata.nrrd
./patient_1/reference/pet/petdata.nrrd
crop results: 
./patient_1/crop/pet/timepoint_1/petdata.nrrd
./patient_1/crop/ct/ctdata.nrrd
registered data:
./patient_1/register/pet/timepoint_1/petdata.nrrd
./patient_1/register/voi/voi.nrrd
voi:
./patient_1/VOIs/voi.nrrd
suv:
./patient_1/results/suv/file.csv
./patient_1/results/plots/plotfiles.
study:
./results/suv/file.csv
./results/plots/plotfiles