code: def _crnn(
      arch: str,
      pretrained: bool,
      backbone_fn,
      pretrained_backbone: bool = True,
      input_shape: Optional[Tuple[int, int, int]] = None,
      **kwargs: Any,
  ) -> CRNN:
      pretrained_backbone = pretrained_backbone and not pretrained
  
      kwargs["vocab"] = kwargs.get("vocab", default_cfgs[arch]["vocab"])
  
      _cfg = deepcopy(default_cfgs[arch])
      _cfg["vocab"] = kwargs["vocab"]
      _cfg["input_shape"] = (
          input_shape or default_cfgs[arch]["input_shape"]
      )
  
      feat_extractor = backbone_fn(
          input_shape=_cfg["input_shape"],
          include_top=False,
          pretrained=pretrained_backbone,
      )
  
      # Build the model
      model = CRNN(feat_extractor, cfg=_cfg, **kwargs)
      # Load pretrained parameters
      if pretrained:
          load_pretrained_params(model, _cfg["url"])
  
      return model
  
imports: from copy import deepcopy
  from typing import Any, Dict, List, Optional, Tuple, Union
  import tensorflow
  from tensorflow.keras import layers
  from tensorflow.keras.models import Model, Sequential
  from doctr.datasets import VOCABS
  from ...classification import mobilenet_v3_large_r, mobilenet_v3_small_r, vgg16_bn_r
  from ...utils.tensorflow import _bf16_to_float32, load_pretrained_params
  from ..core import RecognitionModel, RecognitionPostProcessor
label_desc: Use image node_id 1 for calling a global function with example usage: _crnn(arch, pretrained, backbone_fn, pretrained_backbone, input_shape) and returns: model