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

import typing
import pathlib
from styxdefs import *
import dataclasses

CAT_MATVEC_METADATA = Metadata(
    id="4a0fc2ef1f9e373552cdbe62d1a6bf70fa5b3987.boutiques",
    name="cat_matvec",
    package="afni",
    container_image_tag="afni/afni_make_build:AFNI_24.2.06",
)


class CatMatvecOutputs(typing.NamedTuple):
    """
    Output object returned when calling `cat_matvec(...)`.
    """
    root: OutputPathType
    """Output root folder. This is the root folder for all outputs."""


def cat_matvec(
    matvec_spec: list[str],
    four_by_four_format: bool = False,
    runner: Runner | None = None,
) -> CatMatvecOutputs:
    """
    Catenates 3D rotation+shift matrix+vector transformations.
    
    Author: AFNI Team
    
    URL: https://afni.nimh.nih.gov/pub/dist/doc/program_help/cat_matvec.html
    
    Args:
        matvec_spec: Specifies the matrix transformation. Can take forms\
            described in the documentation.
        four_by_four_format: Output matrix in augmented form (last row is 0 0 0\
            1). This option does not work with -MATRIX or -ONELINE.
        runner: Command runner.
    Returns:
        NamedTuple of outputs (described in `CatMatvecOutputs`).
    """
    runner = runner or get_global_runner()
    execution = runner.start_execution(CAT_MATVEC_METADATA)
    cargs = []
    cargs.append("cat_matvec")
    if four_by_four_format:
        cargs.append("-4x4")
    cargs.extend(matvec_spec)
    ret = CatMatvecOutputs(
        root=execution.output_file("."),
    )
    execution.run(cargs)
    return ret


__all__ = [
    "CAT_MATVEC_METADATA",
    "CatMatvecOutputs",
    "cat_matvec",
]
