Coder Social home page Coder Social logo

Comments (9)

valosekj avatar valosekj commented on June 16, 2024 2

Working after the latest fixes!

image

from spinalcordtoolbox.

joshuacwnewton avatar joshuacwnewton commented on June 16, 2024 1

Oh, oops! My apologies, I definitely skimmed. Thank you for the correction. I'll update the script accordingly, then. :)

from spinalcordtoolbox.

joshuacwnewton avatar joshuacwnewton commented on June 16, 2024 1

Script updated! Please try redownloading the course data by running:

sct_download_data -d sct_course_data -o {path_to_working_directory}

from spinalcordtoolbox.

valosekj avatar valosekj commented on June 16, 2024

I believe the corrected label was not picked up because the manual_correction.py does not add -manual anymore. Instead, the corrected label is named derivatives/labels/sub-05/anat/sub-05_acq-MTon_MTS_seg.nii.gz (ie without -manual). The label provenance is tracked in the JSON sidecar.

The reason why we do not use the -manual suffix anymore is described in this issue:

  • no -manual suffix is used - to be in line with our convention, we do not use the -manual suffix anymore -- the information about the label provenance is stored in the JSON sidecar

To fix this issue, we can:

  1. update the SCT course process_data.sh to not add -manual when looking for the labels under derivatives/labels (lines 52 and 77 in sct_course_data/multi_subject/process_data.sh)
  2. modify manual_correction.py to include -manual again

from spinalcordtoolbox.

jcohenadad avatar jcohenadad commented on June 16, 2024

I would go with "1", if not too late @joshuacwnewton

from spinalcordtoolbox.

joshuacwnewton avatar joshuacwnewton commented on June 16, 2024

It's not too late! (I named the sct_tutorial_data release with the general name "SCT-Course-20231120". This means that as long as we continue to use this name, no updates are needed on SCT's end, which means that any changes to sct_tutorial_data will not block SCT v6.1.)

  1. update the SCT course process_data.sh to not add -manual when looking for the labels under derivatives/labels (lines 52 and 77 in sct_course_data/multi_subject/process_data.sh)

Right now, the script relies on the "-manual" suffix to distinguish between normal segs and corrected segs. Based on the above info, it seems that we would need to change the script to instead look for the presence of a .json sidecar file? (Presuming that non-corrected segs will NOT have the sidecar file.)

from spinalcordtoolbox.

jcohenadad avatar jcohenadad commented on June 16, 2024

Based on the above info, it seems that we would need to change the script to instead look for the presence of a .json sidecar file?

No, I think the difference between a manual and an automatic segmentation is the physical location of the file: a manually corrected file would be located under derivatives/.../. @valosekj can confirm

from spinalcordtoolbox.

valosekj avatar valosekj commented on June 16, 2024

Based on the above info, it seems that we would need to change the script to instead look for the presence of a .json sidecar file?

No, I think the difference between a manual and an automatic segmentation is the physical location of the file: a manually corrected file would be located under derivatives/.../. @valosekj can confirm

Exactly! The automatically generated files (e.g., by sct_deepseg) are located in the output/data_processed folder, while the manually corrected files are stored under derivatives/labels/.

So, I believe that the only modification of the process_data.sh script is to remove -manual from lines 52 and 77.

from spinalcordtoolbox.

jcohenadad avatar jcohenadad commented on June 16, 2024

Also working on my end-- thank you for the fix! ❤️

from spinalcordtoolbox.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.