Maverick/VirtualFamilyTxtToMhdCsv: Difference between revisions

From KitwarePublic
Jump to navigationJump to search
(New page: <h1><center><b>Maverick: VirtualFamilyTxtToMhdCsv</b></center></h1> = Problem = Use this program to convert data from the Virtual Family distribution to use with Maverick and other appli...)
 
No edit summary
Line 1: Line 1:
<h1><center><b>Maverick: VirtualFamilyTxtToMhdCsv</b></center></h1>
<h1><center><b>Maverick: VirtualFamilyTxtToMhdCsv</b></center></h1>


= Problem =


Use this program to convert data from the Virtual Family distribution to use with Maverick and other applications that read and write MetaImages (provided as part of the MetaImage library with ITK and VTK).
= Introduction =


= Useage =
Use this program to import the Virtual Family's data into a format that can be read by Maverick and other ITK and VTK-based applications.
 
The strength of this approach is that it creates the labelmap image file and the corresponding .csv (e.g., the tissue.csv file) that describes the values in the labelmap.
 
== Background ==
 
Each member of the virtual family is offered as a labelmap in multiple resolutions: 0.5mm,, 1mm, 2mm, and 5mm.  In addition to the raw data, a .txt file is associated with each image.  That .txt file lists certain information about the tissues present in the labelmap as well as the dimensions and spacing of the data.  This program converts the .txt files to associated .mhd and .csv files for Maverick applications.
 
== Operation ==
 
This utility program will convert a single .txt file from the virtual family to .mhd and .csv files that describe a labelmap and a tissue lookup table for that labelmap.
 
= Usage =
 
At this time this utility program is only available with a command-line interface.
 
Maverick/bin/VirtualFamilyTxtToMhdCsv <input.txt> <input.raw> <output.mhd> <output.csv>
 
The first argument is the path to the virtual family member's .txt file to be converted.
 
The second argument is the path to that member's raw labelmap data.  Note that the data will not be read or manipulated at this time.  The .mhd file created will merely point to it.  It is highly recommended that the .mhd, .txt, .raw, and .csv file be maintained in the same directory and moved in unison.
 
<em>Hint</em>: The .mhd files are text files.  Any text editor can be used to create or modify these files.    Additional MetaImage documentation is ONLINE.
 
= Use cases =


  VirtualFamilyTxtToMhdCsv Duke_34y_v5_2mm.txt Duke_34y_v5_2mm.raw Duke.mhd Duke.csv
  VirtualFamilyTxtToMhdCsv Duke_34y_v5_2mm.txt Duke_34y_v5_2mm.raw Duke.mhd Duke.csv


  VirtualFamilyTxtToMhdCsv Ella_26y_V2_2mm.txt Ella_26y_V2_2mm.raw Ella.mhd Ella.csv
  VirtualFamilyTxtToMhdCsv Ella_26y_V2_2mm.txt Ella_26y_V2_2mm.raw Ella.mhd Ella.csv
<em>WARNING</em> Maverick applications, in the current release, do not correctly process .mhd files.  You must perform an additional step to convert these .mhd file into complete volumes that are stored as .mha files.  The imageMath command can perform that conversion:
imageMath Duke.mhd -W 3 Duke.mha
imageMath Ella.mhd -W 3 Ella.mha

Revision as of 09:20, 7 October 2008

Maverick: VirtualFamilyTxtToMhdCsv


Introduction

Use this program to import the Virtual Family's data into a format that can be read by Maverick and other ITK and VTK-based applications.

The strength of this approach is that it creates the labelmap image file and the corresponding .csv (e.g., the tissue.csv file) that describes the values in the labelmap.

Background

Each member of the virtual family is offered as a labelmap in multiple resolutions: 0.5mm,, 1mm, 2mm, and 5mm. In addition to the raw data, a .txt file is associated with each image. That .txt file lists certain information about the tissues present in the labelmap as well as the dimensions and spacing of the data. This program converts the .txt files to associated .mhd and .csv files for Maverick applications.

Operation

This utility program will convert a single .txt file from the virtual family to .mhd and .csv files that describe a labelmap and a tissue lookup table for that labelmap.

Usage

At this time this utility program is only available with a command-line interface.

Maverick/bin/VirtualFamilyTxtToMhdCsv <input.txt> <input.raw> <output.mhd> <output.csv>

The first argument is the path to the virtual family member's .txt file to be converted.

The second argument is the path to that member's raw labelmap data. Note that the data will not be read or manipulated at this time. The .mhd file created will merely point to it. It is highly recommended that the .mhd, .txt, .raw, and .csv file be maintained in the same directory and moved in unison.

Hint: The .mhd files are text files. Any text editor can be used to create or modify these files. Additional MetaImage documentation is ONLINE.

Use cases

VirtualFamilyTxtToMhdCsv Duke_34y_v5_2mm.txt Duke_34y_v5_2mm.raw Duke.mhd Duke.csv
VirtualFamilyTxtToMhdCsv Ella_26y_V2_2mm.txt Ella_26y_V2_2mm.raw Ella.mhd Ella.csv

WARNING Maverick applications, in the current release, do not correctly process .mhd files. You must perform an additional step to convert these .mhd file into complete volumes that are stored as .mha files. The imageMath command can perform that conversion:

imageMath Duke.mhd -W 3 Duke.mha
imageMath Ella.mhd -W 3 Ella.mha