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

import typing
import pathlib
from styxdefs import *
import dataclasses

SEGMENT_SUBJECT_NOTAL2_METADATA = Metadata(
    id="6303522667922b1bee80bfcf692f9907c22c58f7.boutiques",
    name="segment_subject_notal2",
    package="freesurfer",
    container_image_tag="freesurfer/freesurfer:7.4.1",
)


class SegmentSubjectNotal2Outputs(typing.NamedTuple):
    """
    Output object returned when calling `segment_subject_notal2(...)`.
    """
    root: OutputPathType
    """Output root folder. This is the root folder for all outputs."""
    output_dir: OutputPathType
    """Output directory containing the segmented results"""


def segment_subject_notal2(
    license_file: InputPathType,
    runner: Runner | None = None,
) -> SegmentSubjectNotal2Outputs:
    """
    FreeSurfer tool for segmenting subject data using notal2 algorithm.
    
    Author: FreeSurfer Developers
    
    URL: https://github.com/freesurfer/freesurfer
    
    Args:
        license_file: FreeSurfer license file is required to run the\
            application. Obtain from\
            http://surfer.nmr.mgh.harvard.edu/registration.html.
        runner: Command runner.
    Returns:
        NamedTuple of outputs (described in `SegmentSubjectNotal2Outputs`).
    """
    runner = runner or get_global_runner()
    execution = runner.start_execution(SEGMENT_SUBJECT_NOTAL2_METADATA)
    cargs = []
    cargs.append("segment_subject_notal2")
    cargs.extend([
        "--fs-license-file",
        execution.input_file(license_file)
    ])
    ret = SegmentSubjectNotal2Outputs(
        root=execution.output_file("."),
        output_dir=execution.output_file("segmented_output"),
    )
    execution.run(cargs)
    return ret


__all__ = [
    "SEGMENT_SUBJECT_NOTAL2_METADATA",
    "SegmentSubjectNotal2Outputs",
    "segment_subject_notal2",
]
