# This file was auto generated by Styx.
# Do not edit this file directly.

import typing
import pathlib
from styxdefs import *
import dataclasses

GCAINIT_METADATA = Metadata(
    id="00dfdd96c6b86f2b1c5b47fc4b41253a5bcd0e9f.boutiques",
    name="gcainit",
    package="freesurfer",
    container_image_tag="freesurfer/freesurfer:7.4.1",
)


class GcainitOutputs(typing.NamedTuple):
    """
    Output object returned when calling `gcainit(...)`.
    """
    root: OutputPathType
    """Output root folder. This is the root folder for all outputs."""


def gcainit(
    gcadir: str,
    runner: Runner | None = None,
) -> GcainitOutputs:
    """
    Initializes the GCA for brain processing tasks.
    
    Author: FreeSurfer Developers
    
    URL: https://github.com/freesurfer/freesurfer
    
    Args:
        gcadir: Output directory of gcaprep.
        runner: Command runner.
    Returns:
        NamedTuple of outputs (described in `GcainitOutputs`).
    """
    runner = runner or get_global_runner()
    execution = runner.start_execution(GCAINIT_METADATA)
    cargs = []
    cargs.append("gcainit")
    cargs.extend([
        "--g",
        gcadir
    ])
    ret = GcainitOutputs(
        root=execution.output_file("."),
    )
    execution.run(cargs)
    return ret


__all__ = [
    "GCAINIT_METADATA",
    "GcainitOutputs",
    "gcainit",
]
