Skip to content

Conversation

@tsalo
Copy link
Collaborator

@tsalo tsalo commented Oct 31, 2025

Closes #503.

Changes proposed:

  • Add a node to init_surface_recon_wf that is only called if --fs-no-resume is used. This node checks if the subject's Freesurfer directory exists and raises an error if it does not.

Copy link
Member

@effigies effigies left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would suggest that we gate the other nodes on this passing, so have it do something like:

fs_params = [(field, field) for field in ('subjects_dir', 'subject_id')]
workflow.connect([
  (inputnode, check_subjects_dir, fs_params),
  (check_subjects_dir, fs_base_inputs, fs_params),
  (check_subjects_dir, get_surfaces, fs_params),
  (check_subjects_dir, save_midthickness, [
      ('subjects_dir', 'base_directory'),
      ('subject_id', 'container'),
  ]),
])

IDC if you actually split out fs_params, I just didn't want to write it a bunch. Also, I'm realizing you could go ahead and collapse get_surfaces into fs_base_inputs/autorecon1, but that's a bit out of scope, so no worries if you don't want to.

@tsalo
Copy link
Collaborator Author

tsalo commented Nov 4, 2025

Sure, I can do that.

@codecov
Copy link

codecov bot commented Nov 6, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 74.77%. Comparing base (da4ee07) to head (fe337a8).
⚠️ Report is 9 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #504      +/-   ##
==========================================
+ Coverage   70.88%   74.77%   +3.88%     
==========================================
  Files          25       25              
  Lines        2068     2077       +9     
  Branches      268      270       +2     
==========================================
+ Hits         1466     1553      +87     
+ Misses        544      456      -88     
- Partials       58       68      +10     
Flag Coverage Δ
ds054 44.83% <ø> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@effigies effigies merged commit bcb3a73 into nipreps:master Nov 6, 2025
23 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Raise informative error if subject's Freesurfer derivatives do not exist when using --fs-no-resume

2 participants