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

import typing
import pathlib
from styxdefs import *
import dataclasses

HIAM_REGISTER_METADATA = Metadata(
    id="44d0a11f2a96d3babdb3cdeabdf7fd3e2408cf2f.boutiques",
    name="hiam_register",
    package="freesurfer",
    container_image_tag="freesurfer/freesurfer:7.4.1",
)


class HiamRegisterOutputs(typing.NamedTuple):
    """
    Output object returned when calling `hiam_register(...)`.
    """
    root: OutputPathType
    """Output root folder. This is the root folder for all outputs."""
    registered_surface: OutputPathType
    """The output surface after registration."""


def hiam_register(
    input_surface: InputPathType,
    average_surface: InputPathType,
    output_surface: str,
    runner: Runner | None = None,
) -> HiamRegisterOutputs:
    """
    This program registers a surface with an average surface.
    
    Author: FreeSurfer Developers
    
    URL: https://github.com/freesurfer/freesurfer
    
    Args:
        input_surface: The input surface to be registered.
        average_surface: The average surface to register against.
        output_surface: The path where the output registered surface will be\
            saved.
        runner: Command runner.
    Returns:
        NamedTuple of outputs (described in `HiamRegisterOutputs`).
    """
    runner = runner or get_global_runner()
    execution = runner.start_execution(HIAM_REGISTER_METADATA)
    cargs = []
    cargs.append("hiam_register")
    cargs.append(execution.input_file(input_surface))
    cargs.append(execution.input_file(average_surface))
    cargs.append(output_surface)
    ret = HiamRegisterOutputs(
        root=execution.output_file("."),
        registered_surface=execution.output_file(output_surface),
    )
    execution.run(cargs)
    return ret


__all__ = [
    "HIAM_REGISTER_METADATA",
    "HiamRegisterOutputs",
    "hiam_register",
]
