ROCm / AMDMIGraphX

AMD's graph optimization engine.
https://rocm.docs.amd.com/projects/AMDMIGraphX/en/latest/
MIT License
185 stars 86 forks source link

Use onnx_name field instead of op_name in MIGRAPHX_THROW as it is more informative and always defined #3532

Closed sohaibnd closed 4 weeks ago

sohaibnd commented 1 month ago

There are onnx parse() functions which use opd.op_name in MIGRAPHX_THROW but this field is not initialized (such as in src/onnx/parse_randomnormal_ops.cpp; see issue). Adding missing definitions for op_name does not seem appropriate since op_name is used to map to operators in src/include/migraphx/op (see calls to make_op). Instead, we can replace uses of op_name in MIGRAPHX_THROW with onnx_name for onnx operators since onnx_name is always defined and is often more descriptive for the user than op_name even when the latter is defined.

codecov[bot] commented 1 month ago

Codecov Report

Attention: Patch coverage is 84.09091% with 7 lines in your changes missing coverage. Please review.

Project coverage is 92.17%. Comparing base (275f854) to head (4128a38). Report is 4 commits behind head on develop.

Files with missing lines Patch % Lines
src/onnx/parse_qlinearbinary.cpp 33.33% 4 Missing :warning:
src/onnx/parse_resize.cpp 66.66% 2 Missing :warning:
src/include/migraphx/tune_axis.hpp 50.00% 1 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## develop #3532 +/- ## ======================================== Coverage 92.17% 92.17% ======================================== Files 512 512 Lines 21391 21393 +2 ======================================== + Hits 19718 19720 +2 Misses 1673 1673 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

migraphx-bot commented 1 month ago
Test Batch Rate new
4128a3
Rate old
ddc4c0
Diff Compare
torchvision-resnet50 64 3,259.67 3,261.96 -0.07% :white_check_mark:
torchvision-resnet50_fp16 64 6,995.62 6,986.50 0.13% :white_check_mark:
torchvision-densenet121 32 2,437.52 2,435.05 0.10% :white_check_mark:
torchvision-densenet121_fp16 32 4,064.50 4,098.64 -0.83% :white_check_mark:
torchvision-inceptionv3 32 1,639.12 1,637.72 0.09% :white_check_mark:
torchvision-inceptionv3_fp16 32 2,761.36 2,760.21 0.04% :white_check_mark:
cadene-inceptionv4 16 776.68 776.83 -0.02% :white_check_mark:
cadene-resnext64x4 16 811.89 812.01 -0.01% :white_check_mark:
slim-mobilenet 64 7,537.21 7,539.31 -0.03% :white_check_mark:
slim-nasnetalarge 64 211.56 211.58 -0.01% :white_check_mark:
slim-resnet50v2 64 3,506.64 3,507.45 -0.02% :white_check_mark:
bert-mrpc-onnx 8 1,147.92 1,148.38 -0.04% :white_check_mark:
bert-mrpc-tf 1 472.01 462.39 2.08% :white_check_mark:
pytorch-examples-wlang-gru 1 418.96 416.01 0.71% :white_check_mark:
pytorch-examples-wlang-lstm 1 391.39 387.25 1.07% :white_check_mark:
torchvision-resnet50_1 1 781.86 799.30 -2.18% :white_check_mark:
cadene-dpn92_1 1 401.00 413.07 -2.92% :white_check_mark:
cadene-resnext101_1 1 376.44 384.54 -2.11% :white_check_mark:
onnx-taau-downsample 1 342.71 343.19 -0.14% :white_check_mark:
dlrm-criteoterabyte 1 33.35 33.33 0.06% :white_check_mark:
dlrm-criteoterabyte_fp16 1 52.73 52.75 -0.05% :white_check_mark:
agentmodel 1 8,441.45 8,254.64 2.26% :white_check_mark:
unet_fp16 2 58.84 58.74 0.17% :white_check_mark:
resnet50v1_fp16 1 944.80 942.04 0.29% :white_check_mark:
resnet50v1_int8 1 999.83 993.52 0.63% :white_check_mark:
bert_base_cased_fp16 64 1,170.33 1,171.05 -0.06% :white_check_mark:
bert_large_uncased_fp16 32 363.54 363.48 0.02% :white_check_mark:
bert_large_fp16 1 200.10 200.70 -0.30% :white_check_mark:
distilgpt2_fp16 16 2,201.48 2,201.26 0.01% :white_check_mark:
yolov5s 1 535.93 537.45 -0.28% :white_check_mark:
tinyllama 1 43.47 43.68 -0.48% :white_check_mark:
vicuna-fastchat 1 173.16 175.99 -1.61% :white_check_mark:
whisper-tiny-encoder 1 418.99 418.69 0.07% :white_check_mark:
whisper-tiny-decoder 1 435.27 428.55 1.57% :white_check_mark:

This build is OK for merge :white_check_mark:

migraphx-bot commented 1 month ago


     :white_check_mark: bert-mrpc-onnx: PASSED: MIGraphX meets tolerance
     :white_check_mark: bert-mrpc-tf: PASSED: MIGraphX meets tolerance
     :white_check_mark: pytorch-examples-wlang-gru: PASSED: MIGraphX meets tolerance
     :white_check_mark: pytorch-examples-wlang-lstm: PASSED: MIGraphX meets tolerance
     :white_check_mark: torchvision-resnet50_1: PASSED: MIGraphX meets tolerance
     :white_check_mark: cadene-dpn92_1: PASSED: MIGraphX meets tolerance
     :white_check_mark: cadene-resnext101_1: PASSED: MIGraphX meets tolerance
     :white_check_mark: dlrm-criteoterabyte: PASSED: MIGraphX meets tolerance
     :white_check_mark: agentmodel: PASSED: MIGraphX meets tolerance
     :white_check_mark: unet: PASSED: MIGraphX meets tolerance
     :white_check_mark: resnet50v1: PASSED: MIGraphX meets tolerance
     :white_check_mark: bert_base_cased_fp16: PASSED: MIGraphX meets tolerance
:red_circle:bert_large_uncased_fp16: FAILED: MIGraphX is not within tolerance - check verbose output

     :white_check_mark: bert_large: PASSED: MIGraphX meets tolerance
     :white_check_mark: yolov5s: PASSED: MIGraphX meets tolerance
     :white_check_mark: tinyllama: PASSED: MIGraphX meets tolerance
     :white_check_mark: vicuna-fastchat: PASSED: MIGraphX meets tolerance
     :white_check_mark: whisper-tiny-encoder: PASSED: MIGraphX meets tolerance
     :white_check_mark: whisper-tiny-decoder: PASSED: MIGraphX meets tolerance
     :white_check_mark: distilgpt2_fp16: PASSED: MIGraphX meets tolerance