Skip to content

Commit

Permalink
ENH: adding a test using sampled phantom dataset
Browse files Browse the repository at this point in the history
Test is done on curves extracted from QIN-PROSTATE-001 dataset (see READMEs for
details)
  • Loading branch information
fedorov committed Oct 13, 2014
1 parent 5eb2908 commit 778fd8c
Show file tree
Hide file tree
Showing 12 changed files with 74 additions and 12 deletions.
78 changes: 66 additions & 12 deletions CLI/Testing/Cxx/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ set(TEMP ${PkModeling_BINARY_DIR}/Testing/Temporary)
#set(DCEMRIDATA ${CMAKE_CURRENT_SOURCE_DIR}/../../Data/DCEMRIData)
#set(DUKEDATA_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../../Data/DukeData)
#set(SYNDATA ${CMAKE_CURRENT_SOURCE_DIR}/../../Data/SyntheticData)
set(QINPROSTATE001 ${CMAKE_CURRENT_SOURCE_DIR}/../../../Data/SampledPhantoms/QINProstate001)

set(CLP ${MODULE_NAME})

Expand All @@ -21,25 +22,78 @@ add_test(NAME ${testname} COMMAND ${Launcher_Command} $<TARGET_FILE:${CLP}Test>
set_property(TEST ${testname} PROPERTY LABELS ${CLP})

#-----------------------------------------------------------------------------
if(DUKEDATA_DIR_DIR)
set(testname ${CLP}TestDukeSyntheticData)
if(QINPROSTATE001)
set(testname QINProstate001)
add_test(NAME ${testname} COMMAND ${Launcher_Command} $<TARGET_FILE:${CLP}Test>
--compare ${QINPROSTATE001}/Baseline/phantom-ktrans.nrrd
${TEMP}/${testname}-ktrans.nrrd
ModuleEntryPoint
--T1Tissue 1000
--T1Blood 1440
--relaxivity 0.0049
--hematocrit 0.45
--T1Tissue 1597
--T1Blood 1600
--relaxivity 0.0039
--S0grad 15.0
--hematocrit 0.4
--aucTimeInterval 90
${DUKEDATA_DIR}/SyntheticDuke.nrrd
${DUKEDATA_DIR}/SyntheticDukeMask.nrrd
--outputKtrans ${TEMP}/ktransVolumeSyn.nrrd
--outputVe ${TEMP}/veVolumeSyn.nrrd
--outputMaxSlope ${TEMP}/maxSlopeVolumeSyn.nrrd
--outputAUC ${TEMP}/AUCVolumeSyn.nrrd
--fTolerance 1e-4
--gTolerance 1e-4
--xTolerance 1e-5
--epsilon 1e-9
--maxIter 200
--outputKtrans ${TEMP}/${testname}-ktrans.nrrd
--outputVe ${TEMP}/${testname}-ve.nrrd
--outputMaxSlope ${TEMP}/${testname}-maxslope.nrrd
--outputAUC ${TEMP}/${testname}-auc.nrrd
--outputBAT ${TEMP}/${testname}-bat.nrrd
--fitted ${TEMP}/${testname}-fit.nrrd
--concentrations ${TEMP}/${testname}-conc.nrrd
--roiMask ${QINPROSTATE001}/Input/${testname}-phantom-ROI.nrrd
--aifMask ${QINPROSTATE001}/Input/${testname}-phantom-AIF.nrrd
${QINPROSTATE001}/Input/${testname}-phantom.nrrd
)
set_property(TEST ${testname} PROPERTY LABELS ${CLP})
endif()

#-----------------------------------------------------------------------------
#if(DUKEDATA_DIR_DIR)
# set(testname ${CLP}TestDukeSyntheticData)
# add_test(NAME ${testname} COMMAND ${Launcher_Command} $<TARGET_FILE:${CLP}Test>
# ModuleEntryPoint
# --T1Tissue 1000
# --T1Blood 1440
# --relaxivity 0.0049
# --hematocrit 0.45
# --aucTimeInterval 90
# ${DUKEDATA_DIR}/SyntheticDuke.nrrd
# ${DUKEDATA_DIR}/SyntheticDukeMask.nrrd
# --outputKtrans ${TEMP}/ktransVolumeSyn.nrrd
# --outputVe ${TEMP}/veVolumeSyn.nrrd
# --outputMaxSlope ${TEMP}/maxSlopeVolumeSyn.nrrd
# --outputAUC ${TEMP}/AUCVolumeSyn.nrrd
# )
# set_property(TEST ${testname} PROPERTY LABELS ${CLP})
#endif()


#-----------------------------------------------------------------------------
#if(DUKEDATA_DIR_DIR)
# set(testname ${CLP}TestDukeSyntheticData)
# add_test(NAME ${testname} COMMAND ${Launcher_Command} $<TARGET_FILE:${CLP}Test>
# ModuleEntryPoint
# --T1Tissue 1000
# --T1Blood 1440
# --relaxivity 0.0049
# --hematocrit 0.45
# --aucTimeInterval 90
# ${DUKEDATA_DIR}/SyntheticDuke.nrrd
# ${DUKEDATA_DIR}/SyntheticDukeMask.nrrd
# --outputKtrans ${TEMP}/ktransVolumeSyn.nrrd
# --outputVe ${TEMP}/veVolumeSyn.nrrd
# --outputMaxSlope ${TEMP}/maxSlopeVolumeSyn.nrrd
# --outputAUC ${TEMP}/AUCVolumeSyn.nrrd
# )
# set_property(TEST ${testname} PROPERTY LABELS ${CLP})
#endif()

#-----------------------------------------------------------------------------
# set(testname ${CLP}TestSmallVolumeOfDukeSyntheticData)
# add_test(NAME ${testname} COMMAND ${Launcher_Command} $<TARGET_FILE:${CLP}Test>
Expand Down
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
5 changes: 5 additions & 0 deletions Data/SampledPhantoms/QINProstate001/README
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
qin01-phantom was generated from QIN-PROSTATE dataset available from TCIA, using
probing.nrrd label.

Details on QIN-PROSTATE collection of TCIA:
https://wiki.cancerimagingarchive.net/display/Public/QIN+Prostate
Binary file added Data/SampledPhantoms/QINProstate001/probing.nrrd
Binary file not shown.
3 changes: 3 additions & 0 deletions Data/SampledPhantoms/README
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
This directory contains phantoms generated from real data using Util/makePhantom.py script.
These "phantoms" are curves sampled from real data, as should be described in the corresponding
READMEs in each directory.

0 comments on commit 778fd8c

Please sign in to comment.