]> Creatis software - clitk.git/blobdiff - scripts/create_midP_masks-2.0.sh
midp masks use new clitkExtractLung version
[clitk.git] / scripts / create_midP_masks-2.0.sh
index 2d9ab8ec2f14f222fca3f74283148654e148622a..eb5983af70ab378ec4b97ae4a887273ce92109cf 100755 (executable)
@@ -43,7 +43,7 @@ extract_bones()
 extract_lungs()
 {
   echo "$phase_file -> Extracting lungs..."  
-  clitkExtractLung -i $phase_file -o $mask_dir_tmp/lungs_$phase_nb.mhd -a $afdb_file --noAutoCrop --doNotSeparateLungs
+  clitkExtractLung -i $phase_file -o $mask_dir_tmp/lungs_$phase_nb.mhd -a $afdb_file --noAutoCrop --doNotSeparateLungs --type 1
 }
 
 
@@ -52,6 +52,7 @@ resample()
 {
   echo "$phase_file -> Resampling..."
   clitkResampleImage -i $mask_dir_tmp/patient_$phase_nb.mhd -o $mask_dir_tmp/patient_$phase_nb.mhd --spacing $resample_spacing --interp $resample_algo
+  clitkResampleImage -i $mask_dir_tmp/patient_mask_$phase_nb.mhd -o $mask_dir_tmp/patient_mask_$phase_nb.mhd --spacing $resample_spacing --interp $resample_algo
   clitkResampleImage -i $mask_dir_tmp/lungs_$phase_nb.mhd -o $mask_dir_tmp/lungs_$phase_nb.mhd --like $mask_dir_tmp/patient_$phase_nb.mhd
 }
 
@@ -145,7 +146,7 @@ mm_postprocessing()
 motion_mask()
 {
   #set cmd line variables
-  mhd4d=$1
+  mhd4d=`basename $1`
   if [ $# -eq 3 ] ; then
     resample_spacing=$2
     resample_algo=$3