AMDMIGraphX icon indicating copy to clipboard operation
AMDMIGraphX copied to clipboard

Add support for Scan operator

Open music-dino opened this issue 10 months ago • 3 comments

  • Implement ONNX parsing support for the Scan operator
  • Resolves https://github.com/migraphx-benchmark/AMDMIGraphX/issues/116

music-dino avatar Apr 01 '24 14:04 music-dino

Test Batch Rate new
9017c1
Rate old
b4c29f
Diff Compare
torchvision-resnet50 64 1,750.14 1,750.01 0.01% :white_check_mark:
torchvision-resnet50_fp16 64 4,178.45 4,178.72 -0.01% :white_check_mark:
torchvision-densenet121 32 1,465.30 1,466.12 -0.06% :white_check_mark:
torchvision-densenet121_fp16 32 2,551.06 2,554.71 -0.14% :white_check_mark:
torchvision-inceptionv3 32 889.00 888.83 0.02% :white_check_mark:
torchvision-inceptionv3_fp16 32 1,493.41 1,494.20 -0.05% :white_check_mark:
cadene-inceptionv4 16 412.16 412.24 -0.02% :white_check_mark:
cadene-resnext64x4 16 419.52 419.57 -0.01% :white_check_mark:
slim-mobilenet 64 4,015.61 4,016.09 -0.01% :white_check_mark:
slim-nasnetalarge 64 101.02 101.00 0.01% :white_check_mark:
slim-resnet50v2 64 1,679.93 1,680.51 -0.03% :white_check_mark:
bert-mrpc-onnx 8 616.30 616.41 -0.02% :white_check_mark:
bert-mrpc-tf 1 279.06 279.98 -0.33% :white_check_mark:
pytorch-examples-wlang-gru 1 333.33 321.71 3.61% :high_brightness:
pytorch-examples-wlang-lstm 1 292.93 293.21 -0.10% :white_check_mark:
torchvision-resnet50_1 1 469.75 471.24 -0.32% :white_check_mark:
cadene-dpn92_1 1 246.48 246.78 -0.12% :white_check_mark:
cadene-resnext101_1 1 203.92 204.01 -0.05% :white_check_mark:
onnx-taau-downsample 1 206.17 206.06 0.05% :white_check_mark:
dlrm-criteoterabyte 1 22.89 22.90 -0.05% :white_check_mark:
dlrm-criteoterabyte_fp16 1 43.86 43.85 0.01% :white_check_mark:
agentmodel 1 6,140.73 6,285.51 -2.30% :white_check_mark:
unet_fp16 2 34.28 34.32 -0.10% :white_check_mark:
resnet50v1_fp16 1 586.72 601.67 -2.48% :white_check_mark:
resnet50v1_int8 1 567.91 567.26 0.12% :white_check_mark:
bert_base_cased_fp16 64 646.54 646.81 -0.04% :white_check_mark:
bert_large_uncased_fp16 32 198.87 198.83 0.02% :white_check_mark:
bert_large_fp16 1 116.81 116.93 -0.10% :white_check_mark:
distilgpt2_fp16 16 1,211.27 1,210.32 0.08% :white_check_mark:
yolov5s 1 301.63 301.46 0.05% :white_check_mark:
tinyllama 1 23.31 23.32 -0.02% :white_check_mark:
vicuna-fastchat 1 133.46 134.89 -1.06% :white_check_mark:
whisper-tiny-encoder 1 244.11 244.10 0.01% :white_check_mark:
whisper-tiny-decoder 1 256.06 256.24 -0.07% :white_check_mark:

Check results before merge :high_brightness:

migraphx-bot avatar Apr 01 '24 16:04 migraphx-bot


     :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

migraphx-bot avatar Apr 01 '24 16:04 migraphx-bot

Codecov Report

Attention: Patch coverage is 96.47887% with 5 lines in your changes missing coverage. Please review.

Project coverage is 92.27%. Comparing base (ee8f12e) to head (cb59a5e). Report is 2 commits behind head on develop.

Files Patch % Lines
src/onnx/parse_scan.cpp 96.29% 4 Missing :warning:
src/include/migraphx/run_loop.hpp 83.33% 1 Missing :warning:
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #2936      +/-   ##
===========================================
+ Coverage    92.24%   92.27%   +0.03%     
===========================================
  Files          495      497       +2     
  Lines        19849    19985     +136     
===========================================
+ Hits         18309    18441     +132     
- Misses        1540     1544       +4     

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

codecov[bot] avatar Apr 02 '24 06:04 codecov[bot]

This is hitting a failure. Build this and run "make check".

[2024-07-17T00:46:28.905Z] 358/358 Test #357: test_py_3.10_backend ......................................................***Failed 965.59 sec

[2024-07-17T00:46:28.905Z] .s.s.s.s.sssssssss.s.s.sssss.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.sssss.sss.sssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssss.s.s.sssssssss.sssssssssssssssssss.s.sssssssssssssssssssssssssssssssss.s.s.s.s.s.s.s.sssssssssssssssssssss.s.s.s.sssssssssssssssssssssssss.s.s.s.sssssssssssssssssssssssss.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.sssssssssssssssssss.s.s.s.s.s.s.s.s.s.s.s.s.sssssssssssss.s.s.s.sssssss.sss.s.s.s.s.s.s.s.s.s.sssssssssssssssssss.s.s.s.sssssssssssssss.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.sss.s.s.s.s.s.s.s.s.s.s.s.s.sssss.s.s.sssss.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.sss.s.s.s.s.s.s.s.s.s.s.s.s.s.sssssssssssssssss.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.sssss.sssss.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.sssssssssssssssssssssss.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.sssssssss.s.s.sss.s.s.s.s.s.s.s.s.s.s.s.s.s.sss.s.s.s.s.s.s.s.s.s.s.s.s.s.sssss.s.s.s.s.s.s.s.s.sssss.sss.sss.sss.sss.sss.sss.sss.sss.sss.sss.sss.sss.sss.sss.sss.sss.sss.sssssssss.sssssssssss.s.s.sssssssssssssssssssssssssssssss.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.sssss.s.sssssssssssss.s.sssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssss.s.sssssssssssssssssssssssssssss.s.sssssssssssss.s.sssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssss.s.sssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssss.s.s.s.s.sEsss.s.s.s.s.s.s.s.s.s.s.s.s.sssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssss.s.s.s.s.s.sssssssssssssssssssssssssssss.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.sssssssssssssssss.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.sssssssssssssssssssssss.s.sssssssssssssssssssss.s.s.s.s.s.s.s.s.s.s.sssssssssssssss.s.s.s.s.s.sssssssssssssssssssssss.s.s.s.s.s.s.s.sss.sssssss.sssss.sssssssssss.sssssssssssssssssssssssssssssss.s.sss.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.sssss.s.s.s.s.s.s.s.s.s.s.s.sss.sss.s.s.s.sss.sss.sss.s.s.s.sss.s.s.s.s.s.s.s.s.s.s.s.sssssssssss.s.s.s.s.s.sss.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.s.sss.s.s.s.s.s.sssssssssssssssssssssssssssss.s.s.sssssssssssss

[2024-07-17T00:46:28.905Z] ======================================================================

[2024-07-17T00:46:28.905Z] ERROR: test_scan9_sum_cpu (main.OnnxBackendNodeModelTest)

[2024-07-17T00:46:28.905Z] ----------------------------------------------------------------------

[2024-07-17T00:46:28.905Z] Traceback (most recent call last):

[2024-07-17T00:46:28.905Z] File "/usr/local/lib/python3.10/dist-packages/onnx/backend/test/runner/init.py", line 290, in device_test_func

[2024-07-17T00:46:28.905Z] return test_func(*args, device=device, **kwargs)

[2024-07-17T00:46:28.905Z] File "/usr/local/lib/python3.10/dist-packages/onnx/backend/test/runner/init.py", line 382, in run

[2024-07-17T00:46:28.905Z] prepared_model = self.backend.prepare(model, device)

[2024-07-17T00:46:28.905Z] File "/home/jenkins/workspace/AMDMIGraphX_PR-2936/build/lib/onnx_migraphx/backend.py", line 125, in prepare

[2024-07-17T00:46:28.905Z] return cls.prepare(bin, device, **kwargs)

[2024-07-17T00:46:28.905Z] File "/home/jenkins/workspace/AMDMIGraphX_PR-2936/build/lib/onnx_migraphx/backend.py", line 112, in prepare

[2024-07-17T00:46:28.905Z] inf = migraphx.parse_onnx_buffer(model)

[2024-07-17T00:46:28.905Z] RuntimeError: /home/jenkins/workspace/AMDMIGraphX_PR-2936/src/onnx/parse_scan.cpp:124: parse: Slice: Sliced scan input 0 shape {float_type, {3}, {1}} does not match corresponding body input shape {float_type, {2}, {1}}

[2024-07-17T00:46:28.905Z]

[2024-07-17T00:46:28.905Z] ----------------------------------------------------------------------

[2024-07-17T00:46:28.905Z] Ran 2634 tests in 963.388s

[2024-07-17T00:46:28.905Z]

[2024-07-17T00:46:28.905Z] FAILED (errors=1, skipped=1896)

[2024-07-17T00:46:28.905Z] Default GPU device is used ....

The issue is resolved.

music-dino avatar Jul 22 '24 09:07 music-dino