Skip to content
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

Testing cervical model on 7T ME-GRE #61

Open
valosekj opened this issue Jun 21, 2024 · 0 comments
Open

Testing cervical model on 7T ME-GRE #61

valosekj opened this issue Jun 21, 2024 · 0 comments

Comments

@valosekj
Copy link
Member

valosekj commented Jun 21, 2024

This issue summarizes testing of the model for dorsal cervical rootlets (sct_deepseg -task seg_spinal_rootlets_t2w) on an axial 7T ME-GRE (T2*w) image (0.24 x 0.24 x 3.0 mm) from Caroline.

TL;DR

The model does not perform well on the provided image out of the box. The performance is significantly lower compared to 3T ME-GRE images (see #60).

0) Preparing data

Data structure
tree
.
...
├── sub-002_run-03_echo-1_t2space.json
├── sub-002_run-03_echo-1_t2space.nii.gz
├── sub-002_run-03_echo-2_t2space.json
├── sub-002_run-03_echo-2_t2space.nii.gz
├── sub-002_run-03_echo-3_t2space.json
├── sub-002_run-03_echo-3_t2space.nii.gz
...

run-03 has the largest FOV --> using it

averaging across echoes
# Combine echos (individual 3D images) into a single 4D image (better for sct_maths)
sct_image -i sub-002_run-03_echo-1_t2space.nii.gz sub-002_run-03_echo-2_t2space.nii.gz sub-002_run-03_echo-3_t2space.nii.gz -concat t -o sub-002_run-03_combined_echos_t2space.nii.gz
# Mean across 4th dim
sct_maths -i sub-002_run-03_combined_echos_t2space.nii.gz -mean t -o sub-002_run-03_combined_echos_t2space_mean.nii.gz
# RMS across 4th dim
sct_maths -i sub-002_run-03_combined_echos_t2space.nii.gz -rms t -o sub-002_run-03_combined_echos_t2space_rms.nii.gz

1) mean image

First trying the model on the mean image:

sct_deepseg -i sub-002_run-03_combined_echos_t2space_mean.nii.gz -o sub-002_run-03_combined_echos_t2space_mean_rootlets.nii.gz -task seg_spinal_rootlets_t2w

Segmentation is totally off -- no rootlets segmented.

image image

2) Cropped mean image

Trying to crop (manually using the FSLeyes crop feature) the image around the SC to limit the FOV before running inference.

sct_deepseg -i sub-002_run-03_combined_echos_t2space_mean_roi.nii.gz -o sub-002_run-03_combined_echos_t2space_mean_roi_rootlets.nii.gz -task seg_spinal_rootlets_t2w

Cropping is not helping much -- only a few rootlets were segmented.

image image

3) Cropped mean image resampled to 0.8 mm

Trying to manually resample the image to iso 0.8 mm to match the resolution of the training data before running inference.

sct_resample -i sub-002_run-03_combined_echos_t2space_mean_roi.nii.gz -mm 0.8x0.8x0.8 -o sub-002_run-03_combined_echos_t2space_mean_roi_r.nii.gz
sct_deepseg -i sub-002_run-03_combined_echos_t2space_mean_r_roi.nii.gz -o sub-002_run-03_combined_echos_t2space_mean_r_roi_rootlets.nii.gz -task seg_spinal_rootlets_t2w

Some rootlets are now segmented, but most of the rootlets are still missing.

image image

Interestingly, the model performs slightly better on the manually resampled image. This is slightly surprising to me because sct_deepseg should do the resampling before running the inference as well.


Results for the rms image are pretty similar --> not showing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant