code: def common_check(self):
      for op in self._model.op:
          mace_check(
              len(op.input) >= 1,
              op.name + ": apu does not support op with 0 input",
          )
          mace_check(
              len(op.output) == 1,
              op.name + ": apu only support single output op",
          )
          mace_check(
              len(op.output) == len(op.output_shape),
              op.name + ": length of output and output_shape not"
              " match",
          )
          mace_check(
              len(op.output_shape[0].dims) <= 4,
              op.name + ": apu only support 1D~4D tensor",
          )
          if (
              op.output_type[0] == mace_pb2.DT_UINT8
              or op.output_type[0] == mace_pb2.DT_INT16
          ):
              mace_check(
                  len(op.output) == len(op.quantize_info),
                  op.name + ": length of output and quantize_info not"
                  " match",
              )
          data_format = ConverterUtil.data_format(op)
          if (
              data_format is not None
              and len(op.output_shape[0].dims) == 4
          ):
              mace_check(
                  (data_format == DataFormat.NHWC)
                  or (data_format == DataFormat.AUTO),
                  op.name + ": apu only support 4D tensor with NHWC"
                  " or AUTO format but find " + str(data_format),
              )
          act_mode_arg = ConverterUtil.get_arg(
              op, MaceKeyword.mace_activation_type_str
          )
          if act_mode_arg is not None:
              mace_check(
                  act_mode_arg.s == b"PRELU"
                  or act_mode_arg.s == b"RELU"
                  or act_mode_arg.s == b"RELUX"
                  or act_mode_arg.s == b"TANH"
                  or act_mode_arg.s == b"SIGMOID",
                  op.name + ": apu only support activation RELU,"
                  " RELUX, TANH and SIGMOID",
              )
      for tensor in self._model.tensors:
          mace_check(
              len(tensor.dims) <= 4,
              tensor.name + ": apu only support 1D~4D tensor",
          )
      for input_info in self._model.input_info:
          mace_check(
              len(input_info.dims) <= 4,
              input_info.name + ": apu only support 1D~4D tensor",
          )
          mace_check(
              input_info.data_type == mace_pb2.DT_FLOAT
              or input_info.data_type == mace_pb2.DT_INT16
              or input_info.data_type == mace_pb2.DT_UINT8,
              input_info.name + ": apu only support "
              "float/uint8/int16 input",
          )
          if len(input_info.dims) == 4:
              mace_check(
                  input_info.data_format == DataFormat.NHWC.value,
                  input_info.name + ": apu only support 4D tensor"
                  " with NHWC format",
              )
  
imports: import copy
  import numpy
  from enum import Enum
  from operator import mul
  from py_proto import mace_pb2
  from transform import base_converter
  from transform.base_converter import ConverterUtil
  from transform.base_converter import EltwiseType
  from transform.base_converter import MaceKeyword
  from transform.base_converter import MaceOp
  from transform.base_converter import PaddingMode
  from transform.base_converter import PadType
  from transform.base_converter import PoolingType
  from transform.base_converter import ReduceType
  from transform.base_converter import DataFormat
  from transform.base_converter import FrameworkType
  from utils.util import mace_check
label_desc: Use image node_id 3 for calling the ApuConverter obj's underlying member method code with example usage: obj.common_check() without return types