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

import typing
import pathlib
from styxdefs import *
import dataclasses

IMDUMP_METADATA = Metadata(
    id="7f8451c2da7ec8cbf2c32a069270cdd298deaee7.boutiques",
    name="imdump",
    package="afni",
    container_image_tag="afni/afni_make_build:AFNI_24.2.06",
)


class ImdumpOutputs(typing.NamedTuple):
    """
    Output object returned when calling `imdump(...)`.
    """
    root: OutputPathType
    """Output root folder. This is the root folder for all outputs."""
    stdout: OutputPathType
    """Nonzero pixels in the format: x-index y-index value, one pixel per
    line."""


def imdump(
    input_image: InputPathType,
    runner: Runner | None = None,
) -> ImdumpOutputs:
    """
    Prints out nonzero pixels in an image.
    
    Author: AFNI Developers
    
    URL: https://afni.nimh.nih.gov/
    
    Args:
        input_image: Input image file to be processed.
        runner: Command runner.
    Returns:
        NamedTuple of outputs (described in `ImdumpOutputs`).
    """
    runner = runner or get_global_runner()
    execution = runner.start_execution(IMDUMP_METADATA)
    cargs = []
    cargs.append("imdump")
    cargs.append(execution.input_file(input_image))
    ret = ImdumpOutputs(
        root=execution.output_file("."),
        stdout=execution.output_file("stdout.txt"),
    )
    execution.run(cargs)
    return ret


__all__ = [
    "IMDUMP_METADATA",
    "ImdumpOutputs",
    "imdump",
]
