SteenMoeller / NORDIC_Raw

Matlab code for performing image reconstruction in MRI and performing the NORDIC denoising
Other
52 stars 24 forks source link

Nipype integration of NIFTI_NORDIC #21

Open MoniDoerig opened 2 weeks ago

MoniDoerig commented 2 weeks ago

Summary of Changes

This pull request introduces modifications to the 'NIFTI_NORDIC.m' script to integrate it with a Nipype workflow, which necessitates new code to handle interactions with Python-generated '.mat' files.

Compatibility Note The updated script is no longer compatible with the original standalone MATLAB usage, which relies on a MATLAB structure (ARG) as an (optional) input. The new version requires a Python-generated .mat file for its operation, which however is also optional.

Changes

  1. Made minor adjustments to the existing NIFTI_NRODIC.m to support the integration with Nipype:

    • New code is added to handle .mat files from Python.
    • The script has been renamed to NIFTI_NORDIC_nipype.m, which also reflects the renaming of the associated function within the script.
  2. Added a new Python module NiftiNordic in NIFTI_NORDIC_interface.py to wrap the NIFTI_NORDIC_nipype.m script for Nipype compatibility.

  3. Included example_usage_NORDIC_nipype.ipynb, a Jupyter Notebook that demonstrates how to use the new Nipype interface with fMRI data and compute TSNR maps.

Proposal

Given that these changes alter the functionality of the original script, I propose that they be merged into a new branch (e.g., nipype-integration) rather than the main branch. This would allow users who work with Nipype to benefit from these modifications without disrupting the original functionality of the NORDIC_raw repository. Please review and let me know if any adjustments are needed.