Example #1
0
        else:
            run_workflow(template, plugin=subj_pipeline_options['plugin_name'], plugin_args=subj_pipeline_options['plugin_args'])

if __name__ == '__main__':
    import sys
    from AutoWorkup import setup_environment

    from docopt import docopt

    argv = docopt(__doc__, version='1.1')
    print(argv)
    if argv['--workphase'] != 'subject-template-generation':
        print("ERROR: Only --workphase subject-template-generation supported for template building")
        sys.exit(-1)
    print('=' * 100)
    environment, experiment, pipeline, cluster = setup_environment(argv)
    from nipype import config as nipype_config
    import nipype.pipeline.engine as pe
    import nipype.interfaces.io as nio
    from nipype.interfaces.utility import IdentityInterface, Function
    import nipype.interfaces.ants as ants

    from PipeLineFunctionHelpers import ConvertSessionsListOfPosteriorListToDictionaryOfSessionLists
    from workflows.atlasNode import MakeAtlasNode, CreateAtlasXMLAndCleanedDeformedAverages
    from utilities.misc import GenerateSubjectOutputPattern as outputPattern
    from utilities.distributed import modify_qsub_args
    from workflows.utils import run_workflow, print_workflow
    from BAWantsRegistrationBuildTemplate import BAWantsRegistrationTemplateBuildSingleIterationWF
    from utilities.configFileParser import nipype_options
    from nipype.interfaces.semtools.testing.generateaveragelmkfile import GenerateAverageLmkFile
    exit = _template_runner(argv, environment, experiment, pipeline, cluster)
Example #2
0
        hasHeader=kwargs["--header"],
    )


def _test():
    """
    Tests doc
    """
    import doctest

    doctest.testmod(verbose=True)
    return 0


if __name__ == "__main__":
    import sys

    from docopt import docopt

    argv = docopt(__doc__, version="1.1")
    print(argv)
    print(("=" * 100))
    from AutoWorkup import setup_environment

    if argv["--test"]:
        sys.exit(_test())
    environment, experiment, pipeline, cluster = setup_environment(argv)
    # from AutoWorkup import setup_environment
    # environment, experiment, pipeline, cluster = setup_envir""
    sys.exit(main(environment, experiment, pipeline, cluster, **argv))