Skip to content
This repository has been archived by the owner on Dec 20, 2024. It is now read-only.

Commit

Permalink
ENH: Add a script to plot the signal estimated by the GP
Browse files Browse the repository at this point in the history
Add a script to plot the signal estimated by the GP as well as the error
data generated by the error analysis script.

Add the necessary helper functions to the signal visualization module to
plot the estimated signal as a surface.

Modify the signal visualization error plotting method to optionally
accept the color the figure size parameters.

Add methods to the the signal simulation module in order to serialize
the dMRI data.

Refactor the the the signal simulation module to:
- Allow the dMRI signal generation method to generate evals randomly if
  not provided.
- Allow reusing the polar random angle generation utility.
- Allow the single tensor method to accept a random generator for the
  sake of reproducibility.
- Set the `zip` function `strict` parameter to `True` as we want all
  iterables to have the same length.

Modify the error analysis script to:
- Reuse the `EddyMotionGPR` instance: factor it out from the CV
  function, as the instance does not change across folds and repeats.
- Save the simulated signal and gtab.
- Predict and save the signal of the GP estimation.
- Save the simulated SNR to the CV scores data file. Since `None`
  indicates no noise, modify the `pandas` serialization method arguments
  so that `None` is not considered as a missing value.

Take advantage of the commit to rename the `evals1` argument to `evals`
in the error analysis script.
  • Loading branch information
jhlegarreta committed Oct 25, 2024
1 parent 8f60576 commit c2d9acb
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/eddymotion/testing/simulations.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,11 @@
from dipy.core.sphere import HemiSphere, Sphere, disperse_charges
from dipy.sims.voxel import all_tensor_evecs, single_tensor

<<<<<<< HEAD
# Bounds defined following Canales-Rodriguez, NIMG 184 2019, https://doi.org/10.1016/j.neuroimage.2018.08.071
=======
# Set according to Canales-Rodriguez, NIMG 184 2019, https://doi.org/10.1016/j.neuroimage.2018.08.071
>>>>>>> 73963e0 (ENH: Add a script to plot the signal estimated by the GP)
BOUNDS_LAMBDA1: tuple[float, float] = (1.4e-3, 1.8e-3)
BOUNDS_LAMBDA23: tuple[float, float] = (0.1e-3, 0.5e-3)

Expand Down

0 comments on commit c2d9acb

Please sign in to comment.