code: def preprocess(self, input_dicts, data_id, log_id):
      ((_, input_dict),) = input_dicts.items()
      raw_im = base64.b64decode(input_dict["image"].encode("utf8"))
      data = np.fromstring(raw_im, np.uint8)
      im = cv2.imdecode(data, cv2.IMREAD_COLOR)
      feed_list = []
      max_wh_ratio = 0
      ## Many mini-batchs, the type of feed_data is list.
      max_batch_size = 6  # len(dt_boxes)
  
      # If max_batch_size is 0, skipping predict stage
      if max_batch_size == 0:
          return {}, True, None, ""
      boxes_size = max_batch_size
      rem = boxes_size % max_batch_size
  
      h, w = im.shape[0:2]
      wh_ratio = w * 1.0 / h
      max_wh_ratio = max(max_wh_ratio, wh_ratio)
      _, w, h = self.ocr_reader.resize_norm_img(im, max_wh_ratio).shape
      norm_img = self.ocr_reader.resize_norm_img(im, max_batch_size)
      norm_img = norm_img[np.newaxis, :]
      feed = {"x": norm_img.copy()}
      feed_list.append(feed)
      return feed_list, False, None, ""
  
file_path: PaddleOCR/deploy/pdserving/web_service_rec.py
imports: from paddle_serving_server.web_service import WebService, Op
  import logging
  import numpy
  import cv2
  import base64
  from ocr_reader import OCRReader, DetResizeForTest, ArgsParser
  from paddle_serving_app.reader import Sequential, ResizeByFactor
  from paddle_serving_app.reader import Div, Normalize, Transpose
label_desc: Use image node_id 2 for calling the RecOp obj's underlying member method code with example usage: obj.preprocess(input_dicts, data_id, log_id) and returns: feed_list,  False,  None,  str, dict,  True,  None,  str