code: def parseq(pretrained: bool = False, **kwargs: Any) -> PARSeq:
      """PARSeq architecture from
      `"Scene Text Recognition with Permuted Autoregressive Sequence Models" <https://arxiv.org/pdf/2207.06966>`_.
  
      >>> import tensorflow as tf
      >>> from doctr.models import parseq
      >>> model = parseq(pretrained=False)
      >>> input_tensor = tf.random.uniform(shape=[1, 32, 128, 3], maxval=1, dtype=tf.float32)
      >>> out = model(input_tensor)
  
      Args:
      ----
          pretrained (bool): If True, returns a model pre-trained on our text recognition dataset
          **kwargs: keyword arguments of the PARSeq architecture
  
      Returns:
      -------
          text recognition architecture
      """
      return _parseq(
          "parseq",
          pretrained,
          vit_s,
          embedding_units=384,
          patch_size=(4, 8),
          **kwargs,
      )
  
imports: import math
  from copy import deepcopy
  from itertools import permutations
  from typing import Any, Dict, List, Optional, Tuple
  import numpy
  import tensorflow
  from tensorflow.keras import Model, layers
  from doctr.datasets import VOCABS
  from doctr.models.modules.transformer import MultiHeadAttention, PositionwiseFeedForward
  from ...classification import vit_s
  from ...utils.tensorflow import _bf16_to_float32, load_pretrained_params
  from .base import _PARSeq, _PARSeqPostProcessor
label_desc: Use image node_id 2 for calling a global function with example usage: parseq(pretrained) and returns: _parseq