Skip to content

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

11 Commits

Folders and files

Repository files navigation

Subspace_DWI.jl

Julia implementation of subspace reconstruction for accelerated high-resolution diffusion-weighted MRI.

This repository contains the reconstruction framework developed for accelerated 3D diffusion MRI of the ex vivo mouse brain.

Two strategies are implemented to estimate the subspace basis:

  • Simulation-based basis: generated from a dictionary of diffusion tensor signals with different eigenvalues and orientations.
  • Calibration-based basis: estimated directly from the fully sampled central region of the k-space.

The subspace reconstruction is performed with the Berkeley Advanced Reconstruction Toolbox (BART) using wavelet regularization.


Overview

The reconstruction pipeline includes:

  1. Reading Bruker diffusion MRI acquisitions.
  2. Conversion of the acquisition to the reconstruction format.
  3. Initial reconstruction for phase estimation.
  4. Correction of inter-volume phase variations.
  5. Generation or calibration of the subspace basis.
  6. Coil sensitivity estimation.
  7. Subspace reconstruction using BART.
  8. Projection of the reconstructed subspace coefficients back into the diffusion-volume domain.

Repository structure

PAPER_subspace_DWI/
|-- src/
|   |-- Subspace_DWI.jl
|   |-- bruker_sequence.jl
|   |-- build_basis.jl
|   `-- subspace_reconstruction.jl
|-- Project.toml
|-- Manifest.toml
`-- README.md

The main source files contain:

  • bruker_sequence.jl: Bruker acquisition handling and conversion.
  • build_basis.jl: diffusion signal simulation and subspace basis generation.
  • subspace_reconstruction.jl: simulation-based and calibration-based subspace reconstruction.
  • Subspace_DWI.jl: main Julia module.

Requirements

The package is developed in Julia and relies mainly on:

  • MRIReco.jl
  • MRIFiles.jl
  • MRICoilSensitivities.jl
  • BartIO.jl
  • LinearAlgebra

The Berkeley Advanced Reconstruction Toolbox (BART) must also be installed separately and accessible from Julia.

For example:

using BartIO

set_bart_path("/path/to/bart")

Installation

Clone the repository:

git clone https://github.com/CRMSB/PAPER_subspace_DWI.git
cd PAPER_subspace_DWI

Start Julia and activate the project:

using Pkg

Pkg.activate(".")
Pkg.instantiate()

The package can then be loaded with:

using Subspace_DWI

Simulation-based subspace basis

The simulation-based approach generates a dictionary of diffusion-weighted signals using the diffusion tensor model:

$$ S(\mathbf{g}) = S_0,\mathrm{e}^{-b,\mathbf{g}^{T}D\mathbf{g}} $$

where:

  • S(g) is the diffusion-weighted signal measured along gradient direction g;
  • S_0 is the signal without diffusion weighting;
  • b is the diffusion-weighting factor;
  • g is the diffusion gradient direction;
  • D is the diffusion tensor;

A set of diffusion tensors is generated by varying:

  • the tensor eigenvalues;
  • the principal diffusion direction over a hemisphere;
  • the orientation of the secondary eigenvectors around the principal axis.

For each simulated tensor:

$$ D = V \Lambda V^{T} $$

where $$\Lambda$$ contains the tensor eigenvalues and $$V$$ contains the corresponding eigenvectors.

The simulated signal dictionary is decomposed using singular value decomposition (SVD), and the dominant right singular vectors are retained to construct the temporal subspace basis.

Example

basis = build_basis(
    bruker_path,
    n_bases,
    n_angles,
    b_value,
    lambda_min,
    lambda_step,
    lambda_max,
    subspace_dim,
)

where:

  • n_bases controls the number of principal diffusion directions;
  • n_angles controls the number of orientations around each principal direction;
  • lambda_min, lambda_step, and lambda_max define the sampling of tensor eigenvalues;
  • subspace_dim defines the number of retained basis vectors.

Simulation-based reconstruction

The simulation-based reconstruction uses the subspace basis generated with the build_basis function described above.

basis = build_basis(
    bruker_path,
    n_bases,
    n_angles,
    b_value,
    lambda_min,
    lambda_step,
    lambda_max,
    subspace_dim,
)

The resulting basis is then provided to the reconstruction function:

subspace_coefficients, reconstructed_images =
    subspace_reconstruction_simulation(
        bruker_path,
        basis,
        iterations,
        regularization,
    )

The input arguments are:

  • bruker_path: path to the prospectively undersampled Bruker dataset;
  • basis: simulated subspace basis generated with build_basis;
  • iterations: number of BART PICS reconstruction iterations;
  • regularization: wavelet regularization parameter used during the subspace reconstruction.

The reconstruction is performed in the reduced subspace domain using BART PICS with spatial wavelet regularization.

The reconstructed subspace coefficients are subsequently projected back into the original diffusion-volume domain.

The function returns:

  • subspace_coefficients: reconstructed coefficient images in the reduced subspace representation;
  • reconstructed_images: reconstructed diffusion volumes in the original diffusion-volume domain.

Calibration-based subspace basis

The calibration-based approach estimates the temporal subspace directly from the acquired data.

A fully sampled central region of k-space is extracted and reconstructed at low spatial resolution before the subspace reconstruction. The resulting diffusion volumes are used to build a calibration dictionary, from which the temporal subspace basis is estimated using singular value decomposition (SVD).

Unlike the simulation-based approach, the subspace basis is therefore generated internally from the calibration data rather than provided as an input. Consequently, the number of retained basis vectors, n_basis, is specified directly in the reconstruction function.

The reconstruction is performed as follows:

subspace_coefficients, reconstructed_images =
    subspace_reconstruction_calibration(
        bruker_path,
        center_size,
        n_basis,
        iterations,
        regularization,
    )

The input arguments are:

  • bruker_path: path to the prospectively undersampled Bruker dataset;
  • center_size: size of the fully sampled central k-space region used to generate the calibration data;
  • n_basis: number of basis vectors retained from the SVD of the calibration dictionary;
  • iterations: number of BART PICS reconstruction iterations;
  • regularization: wavelet regularization parameter used during the subspace reconstruction.

Once the basis has been estimated from the central k-space data, the full undersampled dataset is reconstructed in the reduced subspace domain using BART PICS with spatial wavelet regularization.

The function returns:

  • subspace_coefficients: reconstructed coefficient images in the reduced subspace representation;
  • reconstructed_images: reconstructed diffusion volumes in the original diffusion-volume domain.

Phase correction

A global phase correction is applied across diffusion volumes before subspace reconstruction.

The phase difference between each diffusion volume and the reference volume is estimated from a reference voxel located arbitrarily at the center of the reconstructed volume. The corresponding phase offset is then removed from the k-space data.

This reference selection provides a simple initial strategy for compensating for inter-volume phase variations. Its robustness should nevertheless be further evaluated, and a more dedicated phase-estimation method could be implemented in future developments.


BART reconstruction

The subspace reconstruction relies on the BART PICS framework.

The current reconstruction uses wavelet regularization with:

pics -S -e -R W:7:0:<regularization>

The number of iterations and the regularization strength are specified by the user.

Coil sensitivity maps are estimated using BART ecalib.


Outputs

The reconstruction functions return:

subspace_coefficients, reconstructed_images

where:

  • subspace_coefficients contains the reconstructed coefficient images in the reduced subspace representation;
  • reconstructed_images contains the diffusion volumes reconstructed in the original diffusion-volume domain.

Reproducibility

The Julia dependencies required by the project are defined in Project.toml.

To reproduce the software environment:

using Pkg

Pkg.activate(".")
Pkg.instantiate()

Raw Bruker acquisitions are not distributed directly through this repository.

An example dataset is available on Zenodo and can be used to reproduce the reconstruction workflow described in this repository:

https://zenodo.org/records/22751780

The dataset includes:

  • Bruker dataset 10: fully sampled reference acquisition.
  • Bruker dataset 15: prospectively undersampled acquisition with an acceleration factor of AF = 12.

A complete reconstruction example using these datasets is provided in the examples folder.


Citation

If you use this code in your work, please cite the associated publication:

N. Simonneau et al. Accelerated high-resolution diffusion MRI of the ex vivo mouse brain using subspace reconstruction. Manuscript in preparation.

Citation information will be updated following publication.


Authors

Nicolas Simonneau Centre de Résonance Magnétique des Systemes Biologiques (CRMSB) University of Bordeaux


License

License information will be added before public release.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages