docstr: check input data
  Args:
       texts(list): the input texts to be predicted which the first element is text_1(list)
                    and the second element is text_2(list), such as [['这道题很难'], ['这道题不简单']]
                    if texts not data.
       data(dict): key must be 'text_1' and 'text_2', value is the texts(list) to be predicted
  Returns:
       results(dict): predicted data
docstr_tok: ["check","input","data","Args",":","texts","(","list",")",":","the","input","texts","to","be","predicted","which","the","first","element","is","text_1","(","list",")","and","the","second","element","is","text_2","(","list",")",",","such","as","[","[","'\u8fd9\u9053\u9898\u5f88\u96be","'","]",",","[","'\u8fd9\u9053\u9898\u4e0d\u7b80\u5355","'","]","]","if","texts","not","data",".","data","(","dict",")",":","key","must","be","'text_1","'","and","'text_2","'",",","value","is","the","texts","(","list",")","to","be","predicted","Returns",":","results","(","dict",")",":","predicted","data"]
code: def check_data(self, texts=[], data={}):
      """
      check input data
      Args:
           texts(list): the input texts to be predicted which the first element is text_1(list)
                        and the second element is text_2(list), such as [['这道题很难'], ['这道题不简单']]
                        if texts not data.
           data(dict): key must be 'text_1' and 'text_2', value is the texts(list) to be predicted
      Returns:
           results(dict): predicted data
      """
      predicted_data = {"text_1": [], "text_2": []}
      if (
          texts != []
          and isinstance(texts, list)
          and len(texts) == 2
          and (len(texts[0]) == len(texts[1]))
          and texts[0]
          and texts[1]
          and data == {}
      ):
          predicted_data["text_1"] = texts[0]
          predicted_data["text_2"] = texts[1]
  
      elif (
          texts == []
          and isinstance(data, dict)
          and isinstance(data.get("text_1", None), list)
          and isinstance(data.get("text_2", None), list)
          and (len(data["text_1"]) == len(data["text_2"]))
          and data["text_1"]
          and data["text_2"]
      ):
          predicted_data = data
  
      else:
          raise ValueError(
              "The input data is inconsistent with expectations."
          )
  
      return predicted_data
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import argparse
  import ast
  import json
  import math
  import os
  import numpy
  import six
  from paddle.inference import Config
  from paddle.inference import create_predictor
  from simnet_bow.processor import load_vocab
  from simnet_bow.processor import postprocess
  from simnet_bow.processor import preprocess
  import paddlehub
  from paddlehub.common.paddle_helper import add_vars_prefix
  from paddlehub.common.paddle_helper import get_variable_info
  from paddlehub.common.utils import sys_stdin_encoding
  from paddlehub.io.parser import txt_parser
  from paddlehub.module.module import moduleinfo
  from paddlehub.module.module import runnable
  from paddlehub.module.module import serving
label_desc: Use image node_id 6 for calling the SimnetBow obj's underlying member method code with example usage: obj.check_data(texts, data) and returns: predicted_data