docstr: Tests object detection model through MLIR converter.
docstr_tok: ["Tests","object","detection","model","through","MLIR","converter","."]
code: def testObjectDetectionMLIR(self):
      """Tests object detection model through MLIR converter."""
      self._initObjectDetectionArgs()
      custom_opdefs_str = (
          "name: 'TFLite_Detection_PostProcess' "
          "input_arg: { name: 'raw_outputs/box_encodings' type: DT_FLOAT } "
          "input_arg: { name: 'raw_outputs/class_predictions' type: DT_FLOAT } "
          "input_arg: { name: 'anchors' type: DT_FLOAT } "
          "output_arg: { name: 'TFLite_Detection_PostProcess' type: DT_FLOAT } "
          "output_arg: { name: 'TFLite_Detection_PostProcess:1' "
          "type: DT_FLOAT } "
          "output_arg: { name: 'TFLite_Detection_PostProcess:2' "
          "type: DT_FLOAT } "
          "output_arg: { name: 'TFLite_Detection_PostProcess:3' "
          "type: DT_FLOAT } "
          "attr : { name: 'h_scale' type: 'float'} "
          "attr : { name: 'max_classes_per_detection' type: 'int'} "
          "attr : { name: 'max_detections' type: 'int'} "
          "attr : { name: 'nms_iou_threshold' type: 'float'} "
          "attr : { name: 'nms_score_threshold' type: 'float'} "
          "attr : { name: 'num_classes' type: 'int'} "
          "attr : { name: 'w_scale' type: 'float'} "
          "attr : { name: 'x_scale' type: 'float'} "
          "attr : { name: 'y_scale' type: 'float'}"
      )
  
      flags_str = (
          "--graph_def_file={0} --input_arrays={1} "
          "--output_arrays={2} --input_shapes={3} "
          '--custom_opdefs="{4}"'.format(
              self._graph_def_file,
              self._input_arrays,
              self._output_arrays,
              self._input_shapes,
              custom_opdefs_str,
          )
      )
  
      # Ensure --allow_custom_ops.
      flags_str_final = ("{} --allow_custom_ops").format(flags_str)
  
      self._run(
          flags_str_final,
          should_succeed=True,
          expected_ops_in_converted_model=[
              "TFLite_Detection_PostProcess"
          ],
      )
  
imports: import os
  from absl.testing import parameterized
  import numpy
  from tensorflow import keras
  from tensorflow.core.framework import graph_pb2
  from tensorflow.lite.python import test_util
  from tensorflow.lite.python import tflite_convert
  from tensorflow.lite.python.convert import register_custom_opdefs
  from tensorflow.python import tf2
  from tensorflow.python.client import session
  from tensorflow.python.eager import def_function
  from tensorflow.python.framework import constant_op
  from tensorflow.python.framework import dtypes
  from tensorflow.python.framework import ops
  from tensorflow.python.framework import test_util
  from tensorflow.python.framework.importer import import_graph_def
  from tensorflow.python.ops import array_ops
  from tensorflow.python.ops import random_ops
  from tensorflow.python.platform import gfile
  from tensorflow.python.platform import resource_loader
  from tensorflow.python.platform import test
  from tensorflow.python.saved_model import saved_model
  from tensorflow.python.saved_model.save import save
  from tensorflow.python.trackable import autotrackable
  from tensorflow.python.training.training_util import write_graph
label_desc: Use image node_id 19 for calling the TfLiteConvertV1Test obj's underlying member method code with example usage: obj.testObjectDetectionMLIR() without return types