heudiconv icon indicating copy to clipboard operation
heudiconv copied to clipboard

Replace deprecated "_phase" suffix in reproin heuristic with "part-phase" entity

Open tsalo opened this issue 1 year ago • 3 comments

Closes #769. This is working on DICOMs associated with https://openneuro.org/datasets/ds005250.

Changes proposed:

  • Track previous and next sequence info in ReproIn's infotodict.
  • ~~Rename s variable to curr_seqinfo for improved clarity.~~ Moved to #779.
  • For non-SBRef, non-fieldmap scans, set "part" entity to "phase" for phase data instead of setting the suffix to "phase".
  • For magnitude non-SBRef, non-fieldmap scans, check if the next sequence has the same series_description and is a phase scan. If it is, set "part" to "mag".

tsalo avatar Jun 21 '24 16:06 tsalo

Codecov Report

Attention: Patch coverage is 90.90909% with 2 lines in your changes missing coverage. Please review.

Project coverage is 82.15%. Comparing base (a0a3635) to head (59bb2ec). Report is 16 commits behind head on master.

Files with missing lines Patch % Lines
heudiconv/heuristics/reproin.py 90.90% 2 Missing :warning:
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #770      +/-   ##
==========================================
+ Coverage   82.08%   82.15%   +0.06%     
==========================================
  Files          42       42              
  Lines        4215     4230      +15     
==========================================
+ Hits         3460     3475      +15     
  Misses        755      755              

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

codecov[bot] avatar Jun 24 '24 14:06 codecov[bot]

Rename s variable to curr_seqinfo for improved clarity.

yeah, but complicates review a little due to diff now including changes I can ignore or not and need to decide when looking...

Could you submit a separate PR with that typo fix and such a rename (so no functionality change) and then let's improve this one -- yet to grasp on all the changes, and as we do not have any nice testing for reproin heuristic, I wonder how we could add one :-/ I would really be shy to accept without some way to test. Locally I could do using smth like https://github.com/nipy/heudiconv/blob/master/utils/test-compare-two-versions.sh but could we do better?!

yarikoptic avatar Aug 08 '24 19:08 yarikoptic

:+1: I've opened #779 with the variable name change.

tsalo avatar Aug 08 '24 19:08 tsalo

@tsalo -- ping on this. Would you happen to get time to address comments?

yarikoptic avatar Oct 30 '24 14:10 yarikoptic

Sorry, I've been really busy. I might have time in the next couple of weeks though.

tsalo avatar Oct 30 '24 17:10 tsalo