Abstract
VoxBo (www.voxbo.org) is a distributed processing framework, developed at the Center of Functional Neuroimaging at the University of Penssylvania, with the purpose of processing and analyzing brain functional MRI data. VoxBo is written in C++, and it is escentially a fair translation of some SPM functionality, originally written in Matlab. Along with the software, VoxBo defines two new image formats: 1) .cub, a 3D image format, used for anatomical data and single EPI frames. It is important to notice that this format defines a proper origin field, lacking, for instance, in Analyze. 2) .tes, a 4D image format, designed to contain the temporal EPI information. It is worth noticing that this format organizes the voxels in such a way to optimize longitudinal (temporal) voxel access. Furthermore, the tes format is compressed through encoding of the functional voxels alone, i.e., background voxels are not stored for each frame, but only for the first one. In this work we present the necessary IO classes that allow ImageFileReader and ImageFileWriter to properly identify, read and write .cub files only. We will provide .tes support in a subsequent work. This effort is carried out with the purpose of letting VoxBo implementors to take advantage of ITK's power and overcome the limitations currently afflicting VoxBo.
Keywords
Source Code and Data
Reviews
Josh Cates
Monday 30 October 2006
Summary:
This work is an itk file reader for the VoxBo CUB image format. It supports compressed and uncompressed
files using zlib. An imageIO class and IO factory are provided, along with a test .cub file and a simple test
program. The code conforms to ITK style guidelines, follows the ITK Image IO design pattern and passes
the supplied tests. Some additional work on the testing and documentation might be worth considering.
Open Science:
Both the source code and test data are provided. Revision 2 of this submission includes a CMakeLists.txt file.
Reproducibility:
The code provided compiled without errors on 64-bit SUSE Linux
under gcc 4.1.0 and ITK 2.8.1. I was able to run the test examples given in
the paper without error. Unfortunately I do not have any way to validate the
files produced (see Additional Comments for some suggestions). I did not find
inputTestImage.cub.gz included with the submission. Should the line from page
3 reading "convertImage inputTestImage.cub.gz outputTestImage2.cub" be edited
to read "convertImage outputTestImage1.cub.gz outputTestImage2.cub" instead?
Open Source Contributions:
This code is certainly a valuable contribution for users of the VoxBo software, which is itself an open-source
project.
Code Quality:
The code is written to conform to the ITK style guidelines and is easy to read. If this code is to be considered
for inclusion in ITK, the comment field for the itk::VoxBoCUBImageIO class should be expanded. A
short paragraph that summarizes the Background section of the paper would probably suffice.
Additional Comments:
Note that ITK distributes a version of zlib, so you could use this one instead of relying on the system zlib.
For a more robust test that would be supported by the ITK Dartboard image diff system, you might consider
extracting a 2D slice from the output of convertImage to compare against a known reference image.
Alternatively, you could compute a checksum from the output image data that you compare to a known value.
Sylvain Jaume
Tuesday 5 September 2006
Summary: The paper describes new ITK classes to read and write in CUB format (used by the application VoxBo).
Evidence: I would like to see a 2D slice of the input image and the same slice after conversion. The abstract says \\\‘no extensive testing is presented and no examples are shown.\\\’ But really it should!
Open Science: The paper fully adheres to the concept of Open Science. Source code for the classes and for an application are included. The CMakeLists.txt is missing. Please upload a CMakeLists.txt similar to this one:
PROJECT(VoxBo)
FIND_PACKAGE( ITK REQUIRED ) INCLUDE( ${ITK_USE_FILE} )
ADD_EXECUTABLE(ConvertImage ConvertImage.cxx itkVoxBoCUBImageIO.cxx itkVoxBoCUBImageIOFactory.cxx) TARGET_LINK_LIBRARIES(ConvertImage ITKIO ITKCommon)
ADD_TEST(ConvertImage ${OUTPUT_EXECUTABLE_PATH}/ConvertImage inputTestImage.cub outputTestImage.cub)
One input image is included. However the paper mentions other input images. They should all be included. The output images should also be included as a reference. So the reader could check she/he gets the same output. The author could mention whether the input and output files are exact copies (in which case typing \\\‘diff inputFile outputFile\\\’ would suffice to check the result).
Reproducibility: I could not compile the code. I tried on Windows and Mac. The compiler complains about missing zlib.h. I believe you did run your code and got the results you report in the paper. So please write a CMakeLists.txt with some tests and upload it to the InsightJournal. It will create a Dashboard and, if there is any error when compiling or running your code, you could check the messages and fix the code.
Use of Open Source Software: The author mentions an application called VoxBo. However VoxBo is not required to run the code, but just to check the results.
Open Source Contributions: The author decided to contribute all his source code for the benefit of the community. Thanks! He just misses the CMakeLists.txt which makes this contribution more challenging to test and use.
Code Quality: I discourage using #define. Image dimension and number of arguments could simply be hardcoded since your file format is for 3D images and your application always takes 2 arguments. Second, it is a good idea to insert the Update calls into try/catch blocks particularly for readers/writers:
try { reader->Update(); } catch ( itk::ExceptionObject &err ) { std::cerr << \\\“Exception caught in reader!\\\” << std::endl; std::cerr << err << std::endl; return EXIT_FAILURE; }
writer->SetInput( reader->GetOutput() ); writer->SetFileName( argv[2] ); try { writer->Write(); } catch ( itk::ExceptionObject &err ) { std::cerr << \\\“Exception caught in writer!\\\” << std::endl; std::cerr << err << std::endl; return EXIT_FAILURE; }
Suggestions for future work: I would like to see testing of the conversion from/to CUB and other formats (e.g. MetaImage, Analyze, DICOM). I do understand that some fields may not be propagated.
Requests for additional information from authors: CMakeLists.txt with tests, outputTestImage.cub, and outputTestImage in other formats. Make sure it runs on your platform and other platforms.
Other comments: Writing reader/writer classes is of paramount importance and is often overlooked by the community. It can be very involved to make it successful on all the variants of the file format (consider DICOM!). A big piece of work has been achieved in this contribution, and I believe only some touch-ups are necessary to have this code used by many.
