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

antsApplyTransform doesn't print reason for missing arg error w/o verbosity level #1806

Open
toomanycats opened this issue Nov 15, 2024 · 2 comments
Labels
feature request Ideas for new or improved ANTs features

Comments

@toomanycats
Copy link

Operating system and version

CentOS 7

CPU architecture

x86_64 (PC, Intel Mac, other Intel/AMD)

ANTs code version

2.5.0.post12-g9516f51

ANTs installation type

Compiled from source

Summary of the problem

I'm learning to use the antsApplyTransform command line program. I left out the argument for a reference image and received no warning or other output. I had to echo $? to find out it failed explicitly. Then I ran again with -v and got the error message that I forgot the -r argument.

I think all programs should report why they failed and make it more obvious.
Thanks !

Commands to reproduce the problem.

antsApplyTransforms -d 3 -i foo.nii.gz -o foo_warped.nii.gz -n NearestNeighbor -t bar_xfm.mat

Output of the command with verbose output.

ANTSVERSION=ants-2.5.0
Using double precision for computations.
Input scalar image: foo.nii.gz
A reference image is required.

Data to reproduce the problem

No special data is required.

@cookpa cookpa added the feature request Ideas for new or improved ANTs features label Nov 15, 2024
@cookpa
Copy link
Member

cookpa commented Nov 19, 2024

I'm not sure I can implement this becasue non-verbose output was suppressed for compatibility with ANTsR. I would like to always print on error but I think CRAN had different rules.

@gdevenyi
Copy link
Contributor

I'm not sure I can implement this becasue non-verbose output was suppressed for compatibility with ANTsR.

Shouldn't this be handled properly if errors go to stderr instead of stdout?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request Ideas for new or improved ANTs features
Projects
None yet
Development

No branches or pull requests

3 participants