-
-
Notifications
You must be signed in to change notification settings - Fork 382
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
antsMultivariateTemplateConstruction2.sh repeats N4 on every iteration #1590
Comments
Thanks @gdevenyi . Do you want to put together a pull request or should I put it on my to-do list? |
If you agree this is worth addressing, I can do a PR. Shall I check the other model scripts as well? |
Sure, as to the PR. But what model scripts are you referring to? |
Btp and antsMultivariateTemplateConstruction.sh |
Okay, sure. |
Thanks for this @ntustison and @gdevenyi Should we also remove the default |
I agree that's an issue, but I'm not sure what the default would do without that. In general the tools I write which wrap around ANTs, I usually calculate the largest physical scale of the image and start with that as the N4 distance. |
IMO, ideally we would remove N4 entirely from the template building scripts and simply leave it to the user to do any preprocessing. Outside of that, I agree with @gdevenyi in calculating it on the fly. |
OK I will leave it for now, and think more about how to prepare images in general. |
The location of the N4 code for template construction:
https://github.com/ANTsX/ANTs/blob/master/Scripts/antsMultivariateTemplateConstruction2.sh#L1490-L1492
Results in N4 being re-run on the input files for every iteration of the template construction. Computational time could be saved if it were moved to a step beforehand, or if a file check were added to see if the N4 processed files already exist.
The text was updated successfully, but these errors were encountered: