1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33
|
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Will compare all input files against the first one for the compatibility
of their spatial attributes.
Spatial attributes are: affine, dimensions, voxel sizes and voxel order.
"""
import argparse
from trx.workflows import verify_header_compatibility
def _build_arg_parser():
p = argparse.ArgumentParser(description=__doc__,
formatter_class=argparse.RawTextHelpFormatter)
p.add_argument('in_files', nargs='+',
help='List of file to compare (trk, trx and nii).')
return p
def main():
parser = _build_arg_parser()
args = parser.parse_args()
verify_header_compatibility(args.in_files)
if __name__ == "__main__":
main()
|