-
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
Conversation
config_sct_run_batch.yml
Outdated
@@ -1,6 +1,6 @@ | |||
# config file for sct_run_batch | |||
path_data: /scratch/pabaua/data-multi-subject-p | |||
path_output: /scratch/pabaua/results_csa_t2_2 | |||
path_output: /scratch/pabaua/results_csa_t2_3 |
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.
process_data.sh
Outdated
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 comment
The reason will be displayed to describe this comment to others. Learn more.
problem here, the resampled ${FILESEGMANUAL}_r.nii.gz
should be copied to ${FILESEG}.nii.gz
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.
Suggestion was implemented in commit: 482a704
…into t2w_resample
- update file name resample
process_data.sh
Outdated
@@ -113,7 +114,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 comment
The 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 comment
The 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 comment
The 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
- put interp in config_script.yml
I finally decided to implement issue #91 in this PR with commit 6104cf5. @jcohenadad, i have tested this PR on a couple subjects and it works well. Could you review before merge? |
Co-authored-by: Julien Cohen-Adad <jcohen@polymtl.ca>
Last commits allow user to resample images to desired resolution. This new parameter must be configured in config_script.yml before running program. |
It was noticed in issue #83 that the CSA of rescaled t1w images was often overestimated. This could be caused by an increasing partial volume effect with tissue outside of the CSF. However, overestimation is less visible in t2w images, this is possibly due to better image resolution (0.8x0.8x0.8mm instead of 1x1x1mm). By resampling the T2w data to 1mm at the very beginning, it would be possible to see if difference between t1w and t2w results is caused by difference of native resolution.
DONE:
FIX #91