Enhance preprocessing scripts and checksum comparison functionality - #18
Merged
Conversation
…and clarity fix: enhance checksum comparison logic to report missing sessions and improve output feat: add digest and merge functionality for checksum comparison reports feat: implement session moving and removal scripts with dry-run option
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request standardizes command-line argument naming conventions in the preprocessing scripts and introduces a suite of new tools for analyzing, merging, and managing data checksums and session directories. The most important changes include switching all argument names from dash-separated (e.g.,
--scan-dir) to underscore-separated (e.g.,--scan_dir), improving logging in the DICOM-to-NIfTI conversion script, and adding several new Python utilities for checksum analysis and session management.Command-line argument standardization:
00_preprocess.sh,01_scanDicom.py) now use underscore-separated command-line arguments (e.g.,--scan_dir,--save_dir,--sample_pct) for consistency and clarity. [1] [2] [3] [4] [5]Logging improvements:
03_saveNifti.pyto provide more informative messages about the execution and completion of DICOM-to-NIfTI conversions, including error handling.Checksum analysis and session management tools:
compare_checksum.pyto more accurately flag sessions needing transfer, ready for deletion, or missing from the primary dataset. The summary output now includes a count of sessions missing from primary. [1] [2]digest_comparison.py: Converts a comparison report JSON into plain-text lists of session IDs by category.merge_checksums.py: Merges two checksum scan result files into a unified comparison report, summarizing identical, modified, and unique files.move_sessions.py: Moves session directories listed in a text file from one location to another, with optional dry-run mode.remove_sessions.py: Removes session directories listed in a text file from a target directory, with optional dry-run mode.