class_docstr: Raised when an error occurs during model conversion.
class_docstr_tok: ["Raised","when","an","error","occurs","during","model","conversion","."]
docstr: If the message matches a pattern, assigns the associated error code.
  
  It is difficult to assign an error code to some errrors in MLIR side, Ex:
  errors thrown by other components than TFLite or not using mlir::emitError.
  This function try to detect them by the error message and assign the
  corresponding error code.
  
  Args:
    message: The error message of this exception.
docstr_tok: ["If","the","message","matches","a","pattern",",","assigns","the","associated","error","code",".","It","is","difficult","to","assign","an","error","code","to","some","errrors","in","MLIR","side",",","Ex",":","errors","thrown","by","other","components","than","TFLite","or","not","using","mlir",":",":emitError",".","This","function","try","to","detect","them","by","the","error","message","and","assign","the","corresponding","error","code",".","Args",":","message",":","The","error","message","of","this","exception","."]
code: def _parse_error_message(self, message):
      """If the message matches a pattern, assigns the associated error code.
  
      It is difficult to assign an error code to some errrors in MLIR side, Ex:
      errors thrown by other components than TFLite or not using mlir::emitError.
      This function try to detect them by the error message and assign the
      corresponding error code.
  
      Args:
        message: The error message of this exception.
      """
      error_code_mapping = {
          "Failed to functionalize Control Flow V1 ops. Consider using Control "
          "Flow V2 ops instead. See https://www.tensorflow.org/api_docs/python/"
          "tf/compat/v1/enable_control_flow_v2.": converter_error_data_pb2.ConverterErrorData.ERROR_UNSUPPORTED_CONTROL_FLOW_V1,
      }
      for pattern, error_code in error_code_mapping.items():
          if pattern in message:
              error_data = converter_error_data_pb2.ConverterErrorData()
              error_data.error_message = message
              error_data.error_code = error_code
              self.append_error(error_data)
              return
  
file_path: tensorflow/tensorflow/lite/python/convert_phase.py
imports: import collections
  import enum
  import functools
  from typing import Text
  from tensorflow.lite.python.metrics import converter_error_data_pb2
  from tensorflow.lite.python.metrics import metrics
label_desc: Use image node_id 3 for calling the ConverterError obj's underlying member method code with example usage: obj._parse_error_message(message) without return types