Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gradient sampling ajustment #626

Merged
merged 4 commits into from
Nov 4, 2022

Conversation

karanphil
Copy link
Contributor

Very small change in the scil_generate_gradient_sampling.py script, in order to get a gradient table readable by a Philips scanner. Indeed, Philips scanners require that the gtab have unique pairs of bvecs and bvals for each line. By default, the script outputs the same pair of bvecs [0, 0, 0] and bvals [0] for each bvals in the gtab. The added option simply copies the bvecs from the previous line for each bvals, except the first one.

To test this, simply run the script, for example scil_generate_gradient_sampling.py 16 32 64 dwi --eddy --duty --b0_every 18 --bvals 500 1000 2000 --mrtrix --b0_philips, and make sure that no b0 has the same bvecs.

@arnaudbore arnaudbore self-requested a review October 12, 2022 10:46
@arnaudbore
Copy link
Contributor

Build passed ! Good Job 🍻 !

@arnaudbore
Copy link
Contributor

Build passed ! Good Job 🍻 !

Copy link
Contributor

@EmmaRenauld EmmaRenauld left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested with an without --b0_philips. Works, thanks!

p.s. For future work. Wouldn't we want to add a rng seed option to be able to produce twice the same result?

@arnaudbore
Copy link
Contributor

@EmmaRenauld can you add an issue about improving this with a rng seed option ?

@arnaudbore arnaudbore merged commit 8ec6292 into scilus:master Nov 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants