-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Resample images to desired resolution #85
Changes from 3 commits
49d5adf
8e3012e
0322ce6
d5a9d2e
482a704
e260200
6104cf5
1c3c906
bb4e11f
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -82,10 +82,11 @@ segment_if_does_not_exist(){ | |
local qc=$3 | ||
# Update global variable with segmentation file name | ||
FILESEG="${file}_seg" | ||
FILESEGMANUAL="${path_derivatives}/${FILESEG}-manual.nii.gz" | ||
FILESEGMANUAL="${path_derivatives}/${FILESEG}-manual" | ||
if [ -e $FILESEGMANUAL ]; then | ||
echo "Found! Using manual segmentation." | ||
rsync -avzh $FILESEGMANUAL ${FILESEG}.nii.gz | ||
sct_resample -i ${FILESEGMANUAL}.nii.gz -mm $interp -x nn -o ${FILESEGMANUAL}_r.nii.gz | ||
rsync -avzh ${FILESEGMANUAL}.nii.gz ${FILESEG}.nii.gz | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. problem here, the resampled There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Suggestion was implemented in commit: 482a704 |
||
sct_qc -i ${file}.nii.gz -s ${FILESEG}.nii.gz -p sct_deepseg_sc $qc | ||
else | ||
# Segment spinal cord | ||
|
@@ -117,7 +118,7 @@ cd anat | |
# Reorient to RPI and resample file | ||
if [ $contrast == "t2" ]; then | ||
contrast_str="T2w" | ||
interp="0.8x0.8x0.8" | ||
interp="1x1x1" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. i was suggesting to resample to 1mm iso only for "checking" the effect of this resampling, not for the "stable" release of the pipeline There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Sorry for the confusion, i was thinking of re-running this PR on Compute Canada to put results in the article's supplementary material (It could partly explain differences observed between t1 and t2 results). @jcohenadad, what are your thoughts on that? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. sounds good. IN fact, if we explore the effect of resampling, we probably want to also try other resamplings, e.g. 1.2mm iso |
||
elif [ $contrast == "t1" ]; then | ||
contrast_str="T1w" | ||
interp="1x1x1" | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why these changes? they are local (ie specific to your config)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is to keep track of the configs i used when i run jobs on compute canada. I will not merge this into master. In the future i will fork the repo for these kinds of PRs.