pnlbwh / pnlNipype

PNL pipeline for NIFTI images
Other
10 stars 15 forks source link

Correct way for obtaining epimask #40

Closed tashrifbillah closed 4 years ago

tashrifbillah commented 4 years ago

Compare the reference image of this https://github.com/pnlbwh/pnlNipype/blob/master/scripts/pnl_epi.py#L130

with this https://github.com/pnlbwh/pnlNipype/blob/master/scripts/antsApplyTransformsDWI.py#L19

Check with @sbouix

tashrifbillah commented 4 years ago

Additional information:

Changing the reference image to the mask itself, both of the following yielded valid mask with slight difference:

antsApplyTransforms -d 3 -i /data/pnl/DIAGNOSE_CTE_U01/ek520/5045/diff/5045-dwi-tensormask.nii.gz -o ~/tmp/manual_mask.nii.gz -n NearestNeighbor -r /data/pnl/DIAGNOSE_CTE_U01/ek520/5045/diff/5045-dwi-tensormask.nii.gz -t ~/tmp/epidebug-11897/epiwarp.nii.gz -v

WarpImageMultiTransform 3 /data/pnl/DIAGNOSE_CTE_U01/ek520/5045/diff/5045-dwi-tensormask.nii.gz ~/tmp/manual_mask_WarpImage.nii.gz -R /data/pnl/DIAGNOSE_CTE_U01/ek520/5045/diff/5045-dwi-tensormask.nii.gz --use-NN ~/tmp/epidebug-11897/epiwarp.nii.gz

However, using ~/tmp/epidebug-11897/maskedbse.nii.gz as the reference image gave all zero mask for the above two commands.

tashrifbillah commented 4 years ago

Both mask or bse are fine as a reference for antsApplyTransforms.

The purpose of the reference is solely to provide affine transforms.