towhee.serve.triton.type_gen.handle_type_annotations

towhee.serve.triton.type_gen.handle_type_annotations(type_annotations: List[Tuple[Any, Tuple]], callbacks: Dict[Any, Callable])[source]

Template for handling type annotations

Parameters:
  • type_annotations (List[Tuple[Any, Tuple]]) – a list of type annotations,

  • output (each annotation corresponds to an input or) –

  • of (containing a pair) –

  • typing.List (type class and shape. The supported type classes are) –

:param : :param numpy numerical types (numpy.uint8: :param numpy.uint16: :param numpy.uint32: :param : :param numpy.uint64: :param numpy.int8: :param numpy.int16: :param numpy.int32: :param numpy.int64: :param : :param numpy.float16: :param numpy.float32: :param numpy.float64): :param : :param python numerical types: :type python numerical types: str, bool, int, float :param towhee.types.Image: :param towhee.types.AudioFrame: :param towhee.types.VideoFrame.: :param callbacks: a dict of callback functions. :type callbacks: Dict[Any, Callable]

Returns:

A list of generated codes.