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

[New feature] Topup configuration selection #1111

Open
AlexVCaron opened this issue Dec 17, 2024 · 0 comments
Open

[New feature] Topup configuration selection #1111

AlexVCaron opened this issue Dec 17, 2024 · 0 comments

Comments

@AlexVCaron
Copy link
Collaborator

Context

Since newest versions of FSL (I need to investiguate which one), the recommendations for Topup configuration have changed. They no longer enforce or recommend that input b0 volume have even dimensions.

If you didn't know that, it's related to the subsampling parameter. Topup only chops voxels in equal parts, it doesn't handle the remainder, so the b02b0.cnf configuration only works for even spatial dimensions. Before, they recommended that you remove a slice in odd dimensions to make them even. They recognize it's bad and ask to not do it anymore.

Now, they have added configurations for odd dimensions (basically, you don't subsample, if I understand well), it's named b02b0_1.cnf. There also is a faster configuration, with subsampling 4, b02b0_4.cnf.

Feature

Add topup configuration selection to the script : scil_prepare_topup_command.py.

Proposition 1

Since image dimensions are usually determined are runtime, we should push selection of the configuration file to the script that is generated by the command instead. Topup will be there when it's run, so is $FSLDIR/etc/fslversion, so we can decide based on shape of the b0 images supplied to the script. If the user has given a default configuration using the --config_file argument, the command just skip writing that portion of the script.

Proposition 2

I believe we already check for the presence of topup in the current path (not that it causes an error). We could also check for the presence of the config files, or fetch FSL version in $FSLDIR/etc/fslversion and decide on that. Then we cause an error if the user hasn't supplied a --config_file through the command.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant