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

import typing
import pathlib
from styxdefs import *
import dataclasses

MRIS_SAMPLE_LABEL_METADATA = Metadata(
    id="c932dc0a98511082cdc147b0bac256709172f10e.boutiques",
    name="mris_sample_label",
    package="freesurfer",
    container_image_tag="freesurfer/freesurfer:7.4.1",
)


class MrisSampleLabelOutputs(typing.NamedTuple):
    """
    Output object returned when calling `mris_sample_label(...)`.
    """
    root: OutputPathType
    """Output root folder. This is the root folder for all outputs."""
    output_label_file: OutputPathType
    """The resulting output label file"""


def mris_sample_label(
    input_label_file: InputPathType,
    input_surface_file: InputPathType,
    output_label_file: str,
    runner: Runner | None = None,
) -> MrisSampleLabelOutputs:
    """
    This tool samples a label onto a surface model.
    
    Author: FreeSurfer Developers
    
    URL: https://github.com/freesurfer/freesurfer
    
    Args:
        input_label_file: Input label file.
        input_surface_file: Input surface file.
        output_label_file: Output label file.
        runner: Command runner.
    Returns:
        NamedTuple of outputs (described in `MrisSampleLabelOutputs`).
    """
    runner = runner or get_global_runner()
    execution = runner.start_execution(MRIS_SAMPLE_LABEL_METADATA)
    cargs = []
    cargs.append("mris_sample_label")
    cargs.append(execution.input_file(input_label_file))
    cargs.append(execution.input_file(input_surface_file))
    cargs.append(output_label_file)
    ret = MrisSampleLabelOutputs(
        root=execution.output_file("."),
        output_label_file=execution.output_file(output_label_file),
    )
    execution.run(cargs)
    return ret


__all__ = [
    "MRIS_SAMPLE_LABEL_METADATA",
    "MrisSampleLabelOutputs",
    "mris_sample_label",
]
