code: def __init__(self, config):
      super(StyleTextRec, self).__init__()
      self.logger = get_logger()
      self.text_generator = TextGenerator(
          config["Predictor"]["text_generator"]
      )
      self.bg_generator = BgGeneratorWithMask(
          config["Predictor"]["bg_generator"]
      )
      self.fusion_generator = FusionGeneratorSimple(
          config["Predictor"]["fusion_generator"]
      )
      bg_generator_pretrain = config["Predictor"]["bg_generator"][
          "pretrain"
      ]
      text_generator_pretrain = config["Predictor"]["text_generator"][
          "pretrain"
      ]
      fusion_generator_pretrain = config["Predictor"][
          "fusion_generator"
      ]["pretrain"]
      load_dygraph_pretrain(
          self.bg_generator,
          self.logger,
          path=bg_generator_pretrain,
          load_static_weights=False,
      )
      load_dygraph_pretrain(
          self.text_generator,
          self.logger,
          path=text_generator_pretrain,
          load_static_weights=False,
      )
      load_dygraph_pretrain(
          self.fusion_generator,
          self.logger,
          path=fusion_generator_pretrain,
          load_static_weights=False,
      )
  
imports: import paddle
  import paddle.nn
  from arch.base_module import MiddleNet, ResBlock
  from arch.encoder import Encoder
  from arch.decoder import Decoder, DecoderUnet, SingleDecoder
  from utils.load_params import load_dygraph_pretrain
  from utils.logging import get_logger
label_desc: Use image node_id 1 to create a new StyleTextRec object from inherited base classes: nn with example: obj = StyleTextRec(config)