Skip to content

Commit

Permalink
batch_single_subject.sh: Fix lumbar filenames
Browse files Browse the repository at this point in the history
  • Loading branch information
joshuacwnewton authored Oct 30, 2023
1 parent ac2438c commit fd6f4cd
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions single_subject/batch_single_subject.sh
Original file line number Diff line number Diff line change
Expand Up @@ -218,9 +218,9 @@ sct_register_multimodal -i t1_crop.nii.gz -d ../t2/t2_crop.nii.gz -param step=1,
cd ../t2_lumbar

# Crop full-body image to isolate the lumbar region (lowest 200 axial slices)
sct_crop_image -i t2.nii.gz -zmax 200
sct_crop_image -i t2.nii.gz -zmax 200 -o t2_lumbar.nii.gz
# Use lumbar-specific `sct_deepseg` model to segment the spinal cord
sct_deepseg -i t2_crop.nii.gz -task seg_lumbar_sc_t2w
sct_deepseg -i t2_lumbar.nii.gz -task seg_lumbar_sc_t2w

# Generate labels for the 2 spinal cord landmarks: cauda equinea ('99') and T9-T10 disc ('17')
# Note: Normally this would be done manually using fsleyes' "Edit mode -> Create mask" functionality. (Uncomment below)
Expand All @@ -229,12 +229,12 @@ sct_deepseg -i t2_crop.nii.gz -task seg_lumbar_sc_t2w
#
# However, since this is an automated script with example data, we will place the labels at known locations for the
# sake of reproducing the results in the tutorial.
sct_label_utils -i t2.nii.gz -create 22,77,187,17:27,79,80,60 -o t2_crop_labels.nii.gz
sct_label_utils -i t2.nii.gz -create 22,77,187,17:27,79,80,60 -o t2_lumbar_labels.nii.gz

# Register the image to the template using segmentation and labels
sct_register_to_template -i t2_crop.nii.gz \
-s t2_crop_seg.nii.gz \
-ldisc t2_crop_label.nii.gz \
sct_register_to_template -i t2_lumbar.nii.gz \
-s t2_lumbar_seg.nii.gz \
-ldisc t2_lumbar_labels.nii.gz \
-c t2 -qc qc \
-param step=1,type=seg,algo=centermassrot:step=2,type=seg,algo=bsplinesyn,metric=MeanSquares,iter=3,slicewise=0:step=3,type=im,algo=syn,metric=CC,iter=3,slicewise=0

Expand Down

0 comments on commit fd6f4cd

Please sign in to comment.