# AUTOGENERATED! DO NOT EDIT! File to edit: ../nbs/01_atyp.ipynb.

# %% auto 0
__all__ = ['T', 'O', 'P', 'Ts', 'CoordFormat', 'SliceFormat', 'SliceFormats', 'SliceTuple', 'CoordTuple', 'SliceSpec',
           'SliceSpecs', 'THWCFormat', 'TCHWFormat', 'ChannelsFormats', 'Channels']

# %% ../nbs/01_atyp.ipynb 6
#| export


# %% ../nbs/01_atyp.ipynb 8
from typing import Union, Literal, TypeVar, ParamSpec, TypeAlias, TypeVarTuple, ForwardRef, Iterable

# %% ../nbs/01_atyp.ipynb 10
#| export


# %% ../nbs/01_atyp.ipynb 12
from quac import int4, slicespec, slicelike

# %% ../nbs/01_atyp.ipynb 14
#| export


# %% ../nbs/01_atyp.ipynb 16
T = TypeVar('T')
'''Type variable for generic types''';

O = TypeVar('O')
'''Type variable for generic types reprenesting "other"''';

P = ParamSpec('P')
'''Parameter specification type variable, capturing the type of function parameters.''';

Ts = TypeVarTuple('Ts')

# %% ../nbs/01_atyp.ipynb 19
CoordFormat: TypeAlias = Literal['coord'];

SliceFormat: TypeAlias = Literal['slice'];

SliceFormats: TypeAlias = Union[CoordFormat, SliceFormat]

SliceTuple: TypeAlias = tuple[int | None, int, int | None]
'''Slice format tuple for a `slice`''';

CoordTuple: TypeAlias = tuple[int, ...]
'''Coordinate format tuple for a `slice`''';

SliceSpec: TypeAlias = slice | slicelike | slicespec | SliceTuple | CoordTuple
'''`type[slice] | type[slicelike] | type[slicespec] | type[tuple[int | None, int, int | None]] | type[tuple[int, ...]]`''';

SliceSpecs: TypeAlias = Iterable[SliceSpec]
'''`type[Iterable[slice | slicelike | slicespec | tuple[int | None, int, int | None] | tuple[int, ...]]]`''';

# %% ../nbs/01_atyp.ipynb 21
THWCFormat: TypeAlias = Literal['thwc'];
'''The time, height, width, and channels axis order.''';

TCHWFormat: TypeAlias = Literal['tchw'];
'''The time, channels, height, and width axis order.''';

ChannelsFormats: TypeAlias = Union[THWCFormat, TCHWFormat]

Channels: TypeAlias = Union[ChannelsFormats, str, tuple[int, int, int, int], int4, ForwardRef('Channels', module='etrc.enum', is_class=True)]
'''`Channels | 'thcw' | 'tchw' | (0, 1, 2, 3) | (0, 3, 1, 2)`''';

# %% ../nbs/01_atyp.ipynb 23
#| export
