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

import typing
import pathlib
from styxdefs import *
import dataclasses

MRI_PROBEDICOM_METADATA = Metadata(
    id="e881c56e43ccca97c6f0346fbb32f30273bb1fbf.boutiques",
    name="mri_probedicom",
    package="freesurfer",
    container_image_tag="freesurfer/freesurfer:7.4.1",
)


class MriProbedicomOutputs(typing.NamedTuple):
    """
    Output object returned when calling `mri_probedicom(...)`.
    """
    root: OutputPathType
    """Output root folder. This is the root folder for all outputs."""
    output_file: OutputPathType
    """Text file containing extracted information from DICOM."""


def mri_probedicom(
    dicom_file: InputPathType,
    option1: str | None = None,
    option2: str | None = None,
    runner: Runner | None = None,
) -> MriProbedicomOutputs:
    """
    Utility to probe DICOM files for information.
    
    Author: FreeSurfer Developers
    
    URL: https://github.com/freesurfer/freesurfer
    
    Args:
        dicom_file: DICOM file to be probed.
        option1: Description for option1.
        option2: Description for option2.
        runner: Command runner.
    Returns:
        NamedTuple of outputs (described in `MriProbedicomOutputs`).
    """
    runner = runner or get_global_runner()
    execution = runner.start_execution(MRI_PROBEDICOM_METADATA)
    cargs = []
    cargs.append("mri_probedicom")
    cargs.append(execution.input_file(dicom_file))
    if option1 is not None:
        cargs.extend([
            "-option1",
            option1
        ])
    if option2 is not None:
        cargs.extend([
            "-option2",
            option2
        ])
    ret = MriProbedicomOutputs(
        root=execution.output_file("."),
        output_file=execution.output_file("[OUTPUT].txt"),
    )
    execution.run(cargs)
    return ret


__all__ = [
    "MRI_PROBEDICOM_METADATA",
    "MriProbedicomOutputs",
    "mri_probedicom",
]
