How Do I Determine the Mapping Between Operators in the Original Network Model and Operators Supported by Ascend AI Processors?

Symptom

When you use the Model Accuracy Analyzer or Profiling tool to analyze the operator accuracy or performance, if the accuracy or performance of some operators is abnormal, you may use some options of the ATC tool to adjust the computation precision of the operators, convert the model again, and then perform inference. For example, you can use the --modify_mixlist option to blocklist the faulty operators. In this scenario, the option must be set to an OpType defined based on the Ascend IR.

Here comes the question. How do I obtain the OpType of the operator? Or how do I obtain the OpType of the operator supported by the Ascend AI Processor based on the operator in the original network model?

Solutions

  • If you are using the Profiling tool to analyze the operator performance, directly obtain the operator type supported by the Ascend AI Processor. For details, see Performance Tuning Tool User Guide .
    1. Export the AI Core and AI CPU operator data in the summary data file. The file name is in op_summary_*.csv format.
    2. The OP Type column in the file indicates the OpType supported by Ascend AI Processor.
  • If you are using the Model Accuracy Analyzer to analyze the operator accuracy:
    • Obtain the accuracy analysis result file result_*.csv by referring to Accuracy Debugging Tool Guide.
    • Find the name of the faulty operator based on the NPUDump column in the file, and search for the corresponding OpType in the corresponding dump data file.

      The first segment of the dump data is the OpType supported by Ascend AI Processor, for example, the dump data in the red box of the following figure.