Skip to content

[KMCompiler][Ascend] Add ascend backend for replication_pad2d_backward - #5508

Open
Willing2329 wants to merge 1 commit into
flagos-ai:masterfrom
Willing2329:add_replication_pad2d_backward_ascend
Open

[KMCompiler][Ascend] Add ascend backend for replication_pad2d_backward#5508
Willing2329 wants to merge 1 commit into
flagos-ai:masterfrom
Willing2329:add_replication_pad2d_backward_ascend

Conversation

@Willing2329

Copy link
Copy Markdown
Contributor

PR Category

Operator

Type of Change

Other

Description

Add ascend backend for replication_pad2d_backward op.
The benchmark defaults to operator mode on Ascend via Config.mode = consts.BenchMode.OPERATOR when VENDOR == "ascend". Kernel mode is not used because it relies on do_bench_npu for timing, which currently returns NaN values when profiling this operator on the Ascend backend, making the kernel mode results unreliable.

Issue

Progress

  • Change is properly reviewed (1 reviewer required, 2 recommended).
  • Change is responded to an issue.
  • Change is fully covered by a UT.

Performance

root@bm-ctyun-wq-910b-64g-0-13:/home/secure/qhait/FlagGems# pytest benchmark/test_replication_pad2d_backward.py -s
====================================================================== test session starts =======================================================================
platform linux -- Python 3.11.13, pytest-8.3.2, pluggy-1.6.0
rootdir: /home/secure/qhait/FlagGems
configfile: pytest.ini
plugins: xdist-3.6.1, anyio-4.10.0
collected 1 item                                                                                                                                                 

benchmark/test_replication_pad2d_backward.py 
Operator: replication_pad2d_backward  Performance Test (dtype=torch.float16, mode=operator,level=comprehensive)
Status       Torch Latency (ms)    Gems Latency (ms)         Gems Speedup          Size Detail
-----------------------------------------------------------------------------------------------
SUCCESS               0.073125            0.177979               0.411          [torch.Size([1, 3, 258, 258]), torch.Size([1, 3, 256, 256]), [1, 1, 1, 1]]
SUCCESS               0.071466            0.158668               0.450          [torch.Size([1, 3, 263, 259]), torch.Size([1, 3, 256, 256]), [1, 2, 3, 4]]
SUCCESS               0.072366            0.164353               0.440          [torch.Size([1, 3, 259, 259]), torch.Size([1, 3, 256, 256]), [3, 0, 0, 3]]
SUCCESS               0.071769            0.148468               0.483          [torch.Size([1, 3, 260, 260]), torch.Size([1, 3, 256, 256]), [2, 2, 2, 2]]
SUCCESS               0.165415            0.137115               1.206          [torch.Size([1, 3, 642, 642]), torch.Size([1, 3, 640, 640]), [1, 1, 1, 1]]
SUCCESS               0.163223            0.132842               1.229          [torch.Size([1, 3, 647, 643]), torch.Size([1, 3, 640, 640]), [1, 2, 3, 4]]
SUCCESS               0.164443            0.331822               0.496          [torch.Size([1, 3, 643, 643]), torch.Size([1, 3, 640, 640]), [3, 0, 0, 3]]
SUCCESS               0.182255            0.162572               1.121          [torch.Size([1, 3, 644, 644]), torch.Size([1, 3, 640, 640]), [2, 2, 2, 2]]
SUCCESS               0.249043            0.152868               1.629          [torch.Size([1, 3, 1026, 1026]), torch.Size([1, 3, 1024, 1024]), [1, 1, 1, 1]]
SUCCESS               0.251820            0.128855               1.954          [torch.Size([1, 3, 1031, 1027]), torch.Size([1, 3, 1024, 1024]), [1, 2, 3, 4]]
SUCCESS               0.248648            0.126203               1.970          [torch.Size([1, 3, 1027, 1027]), torch.Size([1, 3, 1024, 1024]), [3, 0, 0, 3]]
SUCCESS               0.249180            0.157206               1.585          [torch.Size([1, 3, 1028, 1028]), torch.Size([1, 3, 1024, 1024]), [2, 2, 2, 2]]
SUCCESS               0.100490            0.156275               0.643          [torch.Size([1, 64, 130, 130]), torch.Size([1, 64, 128, 128]), [1, 1, 1, 1]]
SUCCESS               0.100602            0.155006               0.649          [torch.Size([1, 64, 135, 131]), torch.Size([1, 64, 128, 128]), [1, 2, 3, 4]]
SUCCESS               0.101748            0.153449               0.663          [torch.Size([1, 64, 131, 131]), torch.Size([1, 64, 128, 128]), [3, 0, 0, 3]]
SUCCESS               0.101662            0.148341               0.685          [torch.Size([1, 64, 132, 132]), torch.Size([1, 64, 128, 128]), [2, 2, 2, 2]]
SUCCESS               0.163905            0.152635               1.074          [torch.Size([1, 64, 258, 258]), torch.Size([1, 64, 256, 256]), [1, 1, 1, 1]]
SUCCESS               0.162821            0.136642               1.192          [torch.Size([1, 64, 263, 259]), torch.Size([1, 64, 256, 256]), [1, 2, 3, 4]]
SUCCESS               0.168001            0.150942               1.113          [torch.Size([1, 64, 259, 259]), torch.Size([1, 64, 256, 256]), [3, 0, 0, 3]]
SUCCESS               0.162768            0.148720               1.094          [torch.Size([1, 64, 260, 260]), torch.Size([1, 64, 256, 256]), [2, 2, 2, 2]]
SUCCESS               0.415370            0.201039               2.066          [torch.Size([1, 64, 514, 514]), torch.Size([1, 64, 512, 512]), [1, 1, 1, 1]]
SUCCESS               0.437780            0.230973               1.895          [torch.Size([1, 64, 519, 515]), torch.Size([1, 64, 512, 512]), [1, 2, 3, 4]]
SUCCESS               0.414301            0.157829               2.625          [torch.Size([1, 64, 515, 515]), torch.Size([1, 64, 512, 512]), [3, 0, 0, 3]]
SUCCESS               0.409583            0.227509               1.800          [torch.Size([1, 64, 516, 516]), torch.Size([1, 64, 512, 512]), [2, 2, 2, 2]]
SUCCESS               0.119878            0.145881               0.822          [torch.Size([1, 128, 66, 66]), torch.Size([1, 128, 64, 64]), [1, 1, 1, 1]]
SUCCESS               0.120008            0.151130               0.794          [torch.Size([1, 128, 71, 67]), torch.Size([1, 128, 64, 64]), [1, 2, 3, 4]]
SUCCESS               0.120539            0.140574               0.857          [torch.Size([1, 128, 67, 67]), torch.Size([1, 128, 64, 64]), [3, 0, 0, 3]]
SUCCESS               0.120400            0.142675               0.844          [torch.Size([1, 128, 68, 68]), torch.Size([1, 128, 64, 64]), [2, 2, 2, 2]]
SUCCESS               0.029288            0.139567               0.210          [torch.Size([1, 256, 34, 34]), torch.Size([1, 256, 32, 32]), [1, 1, 1, 1]]
SUCCESS               0.033089            0.145693               0.227          [torch.Size([1, 256, 39, 35]), torch.Size([1, 256, 32, 32]), [1, 2, 3, 4]]
SUCCESS               0.027473            0.138814               0.198          [torch.Size([1, 256, 35, 35]), torch.Size([1, 256, 32, 32]), [3, 0, 0, 3]]
SUCCESS               0.031508            0.145253               0.217          [torch.Size([1, 256, 36, 36]), torch.Size([1, 256, 32, 32]), [2, 2, 2, 2]]
SUCCESS               0.088473            0.139054               0.636          [torch.Size([4, 8, 258, 258]), torch.Size([4, 8, 256, 256]), [1, 1, 1, 1]]
SUCCESS               0.089760            0.140016               0.641          [torch.Size([4, 8, 263, 259]), torch.Size([4, 8, 256, 256]), [1, 2, 3, 4]]
SUCCESS               0.089202            0.166016               0.537          [torch.Size([4, 8, 259, 259]), torch.Size([4, 8, 256, 256]), [3, 0, 0, 3]]
SUCCESS               0.088858            0.137526               0.646          [torch.Size([4, 8, 260, 260]), torch.Size([4, 8, 256, 256]), [2, 2, 2, 2]]
SUCCESS               0.520182            0.425542               1.222          [torch.Size([8, 64, 130, 130]), torch.Size([8, 64, 128, 128]), [1, 1, 1, 1]]
SUCCESS               0.519946            0.466550               1.114          [torch.Size([8, 64, 135, 131]), torch.Size([8, 64, 128, 128]), [1, 2, 3, 4]]
SUCCESS               0.521553            0.243751               2.140          [torch.Size([8, 64, 131, 131]), torch.Size([8, 64, 128, 128]), [3, 0, 0, 3]]
SUCCESS               0.519055            0.471160               1.102          [torch.Size([8, 64, 132, 132]), torch.Size([8, 64, 128, 128]), [2, 2, 2, 2]]
SUCCESS              22.173107            7.526288               2.946          [torch.Size([8, 128, 1026, 1026]), torch.Size([8, 128, 1024, 1024]), [1, 1, 1, 1]]
SUCCESS              22.309065            8.411082               2.652          [torch.Size([8, 128, 1031, 1027]), torch.Size([8, 128, 1024, 1024]), [1, 2, 3, 4]]
SUCCESS              22.939622            5.569249               4.119          [torch.Size([8, 128, 1027, 1027]), torch.Size([8, 128, 1024, 1024]), [3, 0, 0, 3]]
SUCCESS              22.267759            8.700197               2.559          [torch.Size([8, 128, 1028, 1028]), torch.Size([8, 128, 1024, 1024]), [2, 2, 2, 2]]
SUCCESS               0.054431            0.335789               0.162          [torch.Size([3, 130, 130]), torch.Size([3, 128, 128]), [1, 1, 1, 1]]
SUCCESS               0.043795            0.167444               0.262          [torch.Size([3, 135, 131]), torch.Size([3, 128, 128]), [1, 2, 3, 4]]
SUCCESS               0.044238            0.159822               0.277          [torch.Size([3, 131, 131]), torch.Size([3, 128, 128]), [3, 0, 0, 3]]
SUCCESS               0.045940            0.159394               0.288          [torch.Size([3, 132, 132]), torch.Size([3, 128, 128]), [2, 2, 2, 2]]
SUCCESS               0.032004            0.149098               0.215          [torch.Size([1, 32, 3, 130]), torch.Size([1, 32, 1, 128]), [1, 1, 1, 1]]
SUCCESS               0.029926            0.150306               0.199          [torch.Size([1, 32, 8, 131]), torch.Size([1, 32, 1, 128]), [1, 2, 3, 4]]
SUCCESS               0.029475            0.147038               0.200          [torch.Size([1, 32, 4, 131]), torch.Size([1, 32, 1, 128]), [3, 0, 0, 3]]
SUCCESS               0.028351            0.142063               0.200          [torch.Size([1, 32, 5, 132]), torch.Size([1, 32, 1, 128]), [2, 2, 2, 2]]


Operator: replication_pad2d_backward  Performance Test (dtype=torch.float32, mode=operator,level=comprehensive)
Status       Torch Latency (ms)    Gems Latency (ms)         Gems Speedup          Size Detail
-----------------------------------------------------------------------------------------------
SUCCESS               0.065103            0.148467               0.439          [torch.Size([1, 3, 258, 258]), torch.Size([1, 3, 256, 256]), [1, 1, 1, 1]]
SUCCESS               0.066496            0.149184               0.446          [torch.Size([1, 3, 263, 259]), torch.Size([1, 3, 256, 256]), [1, 2, 3, 4]]
SUCCESS               0.065680            0.149403               0.440          [torch.Size([1, 3, 259, 259]), torch.Size([1, 3, 256, 256]), [3, 0, 0, 3]]
SUCCESS               0.066323            0.148245               0.447          [torch.Size([1, 3, 260, 260]), torch.Size([1, 3, 256, 256]), [2, 2, 2, 2]]
SUCCESS               0.156630            0.148481               1.055          [torch.Size([1, 3, 642, 642]), torch.Size([1, 3, 640, 640]), [1, 1, 1, 1]]
SUCCESS               0.155966            0.145937               1.069          [torch.Size([1, 3, 647, 643]), torch.Size([1, 3, 640, 640]), [1, 2, 3, 4]]
SUCCESS               0.156140            0.145715               1.072          [torch.Size([1, 3, 643, 643]), torch.Size([1, 3, 640, 640]), [3, 0, 0, 3]]
SUCCESS               0.156386            0.147109               1.063          [torch.Size([1, 3, 644, 644]), torch.Size([1, 3, 640, 640]), [2, 2, 2, 2]]
SUCCESS               0.238383            0.137870               1.729          [torch.Size([1, 3, 1026, 1026]), torch.Size([1, 3, 1024, 1024]), [1, 1, 1, 1]]
SUCCESS               0.237437            0.138708               1.712          [torch.Size([1, 3, 1031, 1027]), torch.Size([1, 3, 1024, 1024]), [1, 2, 3, 4]]
SUCCESS               0.237402            0.137584               1.726          [torch.Size([1, 3, 1027, 1027]), torch.Size([1, 3, 1024, 1024]), [3, 0, 0, 3]]
SUCCESS               0.238168            0.136644               1.743          [torch.Size([1, 3, 1028, 1028]), torch.Size([1, 3, 1024, 1024]), [2, 2, 2, 2]]
SUCCESS               0.078756            0.141214               0.558          [torch.Size([1, 64, 130, 130]), torch.Size([1, 64, 128, 128]), [1, 1, 1, 1]]
SUCCESS               0.078483            0.143757               0.546          [torch.Size([1, 64, 135, 131]), torch.Size([1, 64, 128, 128]), [1, 2, 3, 4]]
SUCCESS               0.079138            0.144330               0.548          [torch.Size([1, 64, 131, 131]), torch.Size([1, 64, 128, 128]), [3, 0, 0, 3]]
SUCCESS               0.078730            0.141424               0.557          [torch.Size([1, 64, 132, 132]), torch.Size([1, 64, 128, 128]), [2, 2, 2, 2]]
SUCCESS               0.132712            0.138603               0.958          [torch.Size([1, 64, 258, 258]), torch.Size([1, 64, 256, 256]), [1, 1, 1, 1]]
SUCCESS               0.132245            0.133774               0.989          [torch.Size([1, 64, 263, 259]), torch.Size([1, 64, 256, 256]), [1, 2, 3, 4]]
SUCCESS               0.132479            0.135119               0.980          [torch.Size([1, 64, 259, 259]), torch.Size([1, 64, 256, 256]), [3, 0, 0, 3]]
SUCCESS               0.132676            0.137390               0.966          [torch.Size([1, 64, 260, 260]), torch.Size([1, 64, 256, 256]), [2, 2, 2, 2]]
SUCCESS               0.262042            0.188204               1.392          [torch.Size([1, 64, 514, 514]), torch.Size([1, 64, 512, 512]), [1, 1, 1, 1]]
SUCCESS               0.268910            0.217160               1.238          [torch.Size([1, 64, 519, 515]), torch.Size([1, 64, 512, 512]), [1, 2, 3, 4]]
SUCCESS               0.265058            0.137715               1.925          [torch.Size([1, 64, 515, 515]), torch.Size([1, 64, 512, 512]), [3, 0, 0, 3]]
SUCCESS               0.265601            0.209833               1.266          [torch.Size([1, 64, 516, 516]), torch.Size([1, 64, 512, 512]), [2, 2, 2, 2]]
SUCCESS               0.098282            0.137220               0.716          [torch.Size([1, 128, 66, 66]), torch.Size([1, 128, 64, 64]), [1, 1, 1, 1]]
SUCCESS               0.098396            0.139094               0.707          [torch.Size([1, 128, 71, 67]), torch.Size([1, 128, 64, 64]), [1, 2, 3, 4]]
SUCCESS               0.098955            0.134611               0.735          [torch.Size([1, 128, 67, 67]), torch.Size([1, 128, 64, 64]), [3, 0, 0, 3]]
SUCCESS               0.098573            0.137660               0.716          [torch.Size([1, 128, 68, 68]), torch.Size([1, 128, 64, 64]), [2, 2, 2, 2]]
SUCCESS               0.031622            0.134840               0.235          [torch.Size([1, 256, 34, 34]), torch.Size([1, 256, 32, 32]), [1, 1, 1, 1]]
SUCCESS               0.030828            0.136079               0.227          [torch.Size([1, 256, 39, 35]), torch.Size([1, 256, 32, 32]), [1, 2, 3, 4]]
SUCCESS               0.031122            0.134339               0.232          [torch.Size([1, 256, 35, 35]), torch.Size([1, 256, 32, 32]), [3, 0, 0, 3]]
SUCCESS               0.030739            0.134706               0.228          [torch.Size([1, 256, 36, 36]), torch.Size([1, 256, 32, 32]), [2, 2, 2, 2]]
SUCCESS               0.068781            0.140218               0.491          [torch.Size([4, 8, 258, 258]), torch.Size([4, 8, 256, 256]), [1, 1, 1, 1]]
SUCCESS               0.068221            0.141088               0.484          [torch.Size([4, 8, 263, 259]), torch.Size([4, 8, 256, 256]), [1, 2, 3, 4]]
SUCCESS               0.068160            0.144659               0.471          [torch.Size([4, 8, 259, 259]), torch.Size([4, 8, 256, 256]), [3, 0, 0, 3]]
SUCCESS               0.068379            0.141069               0.485          [torch.Size([4, 8, 260, 260]), torch.Size([4, 8, 256, 256]), [2, 2, 2, 2]]
SUCCESS               0.486475            0.366336               1.328          [torch.Size([8, 64, 130, 130]), torch.Size([8, 64, 128, 128]), [1, 1, 1, 1]]
SUCCESS               0.475783            0.388868               1.224          [torch.Size([8, 64, 135, 131]), torch.Size([8, 64, 128, 128]), [1, 2, 3, 4]]
SUCCESS               0.477191            0.133392               3.577          [torch.Size([8, 64, 131, 131]), torch.Size([8, 64, 128, 128]), [3, 0, 0, 3]]
SUCCESS               0.477371            0.394279               1.211          [torch.Size([8, 64, 132, 132]), torch.Size([8, 64, 128, 128]), [2, 2, 2, 2]]
SUCCESS              11.531740            9.190893               1.255          [torch.Size([8, 128, 1026, 1026]), torch.Size([8, 128, 1024, 1024]), [1, 1, 1, 1]]
SUCCESS              11.625648            9.781051               1.189          [torch.Size([8, 128, 1031, 1027]), torch.Size([8, 128, 1024, 1024]), [1, 2, 3, 4]]
SUCCESS              11.577696            8.349744               1.387          [torch.Size([8, 128, 1027, 1027]), torch.Size([8, 128, 1024, 1024]), [3, 0, 0, 3]]
SUCCESS              11.627555            9.763813               1.191          [torch.Size([8, 128, 1028, 1028]), torch.Size([8, 128, 1024, 1024]), [2, 2, 2, 2]]
SUCCESS               0.040079            0.156076               0.257          [torch.Size([3, 130, 130]), torch.Size([3, 128, 128]), [1, 1, 1, 1]]
SUCCESS               0.038263            0.166441               0.230          [torch.Size([3, 135, 131]), torch.Size([3, 128, 128]), [1, 2, 3, 4]]
SUCCESS               0.038697            0.150100               0.258          [torch.Size([3, 131, 131]), torch.Size([3, 128, 128]), [3, 0, 0, 3]]
SUCCESS               0.039203            0.146783               0.267          [torch.Size([3, 132, 132]), torch.Size([3, 128, 128]), [2, 2, 2, 2]]
SUCCESS               0.032400            0.133004               0.244          [torch.Size([1, 32, 3, 130]), torch.Size([1, 32, 1, 128]), [1, 1, 1, 1]]
SUCCESS               0.026309            0.132529               0.199          [torch.Size([1, 32, 8, 131]), torch.Size([1, 32, 1, 128]), [1, 2, 3, 4]]
SUCCESS               0.029757            0.134667               0.221          [torch.Size([1, 32, 4, 131]), torch.Size([1, 32, 1, 128]), [3, 0, 0, 3]]
SUCCESS               0.026846            0.132470               0.203          [torch.Size([1, 32, 5, 132]), torch.Size([1, 32, 1, 128]), [2, 2, 2, 2]]


Operator: replication_pad2d_backward  Performance Test (dtype=torch.bfloat16, mode=operator,level=comprehensive)
Status       Torch Latency (ms)    Gems Latency (ms)         Gems Speedup          Size Detail
-----------------------------------------------------------------------------------------------
SUCCESS               0.071124            0.165917               0.429          [torch.Size([1, 3, 258, 258]), torch.Size([1, 3, 256, 256]), [1, 1, 1, 1]]
SUCCESS               0.071139            0.140799               0.505          [torch.Size([1, 3, 263, 259]), torch.Size([1, 3, 256, 256]), [1, 2, 3, 4]]
SUCCESS               0.070732            0.129708               0.545          [torch.Size([1, 3, 259, 259]), torch.Size([1, 3, 256, 256]), [3, 0, 0, 3]]
SUCCESS               0.071404            0.153286               0.466          [torch.Size([1, 3, 260, 260]), torch.Size([1, 3, 256, 256]), [2, 2, 2, 2]]
SUCCESS               0.168331            0.142330               1.183          [torch.Size([1, 3, 642, 642]), torch.Size([1, 3, 640, 640]), [1, 1, 1, 1]]
SUCCESS               0.163195            0.130190               1.254          [torch.Size([1, 3, 647, 643]), torch.Size([1, 3, 640, 640]), [1, 2, 3, 4]]
SUCCESS               0.163211            0.137978               1.183          [torch.Size([1, 3, 643, 643]), torch.Size([1, 3, 640, 640]), [3, 0, 0, 3]]
SUCCESS               0.163447            0.132671               1.232          [torch.Size([1, 3, 644, 644]), torch.Size([1, 3, 640, 640]), [2, 2, 2, 2]]
SUCCESS               0.248776            0.136740               1.819          [torch.Size([1, 3, 1026, 1026]), torch.Size([1, 3, 1024, 1024]), [1, 1, 1, 1]]
SUCCESS               0.247844            0.125129               1.981          [torch.Size([1, 3, 1031, 1027]), torch.Size([1, 3, 1024, 1024]), [1, 2, 3, 4]]
SUCCESS               0.248146            0.128054               1.938          [torch.Size([1, 3, 1027, 1027]), torch.Size([1, 3, 1024, 1024]), [3, 0, 0, 3]]
SUCCESS               0.248747            0.130690               1.903          [torch.Size([1, 3, 1028, 1028]), torch.Size([1, 3, 1024, 1024]), [2, 2, 2, 2]]
SUCCESS               0.099069            0.130302               0.760          [torch.Size([1, 64, 130, 130]), torch.Size([1, 64, 128, 128]), [1, 1, 1, 1]]
SUCCESS               0.098900            0.130564               0.757          [torch.Size([1, 64, 135, 131]), torch.Size([1, 64, 128, 128]), [1, 2, 3, 4]]
SUCCESS               0.099854            0.132509               0.754          [torch.Size([1, 64, 131, 131]), torch.Size([1, 64, 128, 128]), [3, 0, 0, 3]]
SUCCESS               0.099882            0.132556               0.754          [torch.Size([1, 64, 132, 132]), torch.Size([1, 64, 128, 128]), [2, 2, 2, 2]]
SUCCESS               0.160687            0.128190               1.254          [torch.Size([1, 64, 258, 258]), torch.Size([1, 64, 256, 256]), [1, 1, 1, 1]]
SUCCESS               0.161092            0.124377               1.295          [torch.Size([1, 64, 263, 259]), torch.Size([1, 64, 256, 256]), [1, 2, 3, 4]]
SUCCESS               0.161343            0.126677               1.274          [torch.Size([1, 64, 259, 259]), torch.Size([1, 64, 256, 256]), [3, 0, 0, 3]]
SUCCESS               0.161540            0.126190               1.280          [torch.Size([1, 64, 260, 260]), torch.Size([1, 64, 256, 256]), [2, 2, 2, 2]]
SUCCESS               0.414172            0.201221               2.058          [torch.Size([1, 64, 514, 514]), torch.Size([1, 64, 512, 512]), [1, 1, 1, 1]]
SUCCESS               0.409504            0.224590               1.823          [torch.Size([1, 64, 519, 515]), torch.Size([1, 64, 512, 512]), [1, 2, 3, 4]]
SUCCESS               0.414148            0.138304               2.994          [torch.Size([1, 64, 515, 515]), torch.Size([1, 64, 512, 512]), [3, 0, 0, 3]]
SUCCESS               0.408192            0.229427               1.779          [torch.Size([1, 64, 516, 516]), torch.Size([1, 64, 512, 512]), [2, 2, 2, 2]]
SUCCESS               0.118500            0.130684               0.907          [torch.Size([1, 128, 66, 66]), torch.Size([1, 128, 64, 64]), [1, 1, 1, 1]]
SUCCESS               0.118745            0.137555               0.863          [torch.Size([1, 128, 71, 67]), torch.Size([1, 128, 64, 64]), [1, 2, 3, 4]]
SUCCESS               0.119470            0.142161               0.840          [torch.Size([1, 128, 67, 67]), torch.Size([1, 128, 64, 64]), [3, 0, 0, 3]]
SUCCESS               0.118796            0.134340               0.884          [torch.Size([1, 128, 68, 68]), torch.Size([1, 128, 64, 64]), [2, 2, 2, 2]]
SUCCESS               0.026977            0.134336               0.201          [torch.Size([1, 256, 34, 34]), torch.Size([1, 256, 32, 32]), [1, 1, 1, 1]]
SUCCESS               0.029099            0.143788               0.202          [torch.Size([1, 256, 39, 35]), torch.Size([1, 256, 32, 32]), [1, 2, 3, 4]]
SUCCESS               0.027489            0.130194               0.211          [torch.Size([1, 256, 35, 35]), torch.Size([1, 256, 32, 32]), [3, 0, 0, 3]]
SUCCESS               0.027813            0.138679               0.201          [torch.Size([1, 256, 36, 36]), torch.Size([1, 256, 32, 32]), [2, 2, 2, 2]]
SUCCESS               0.087722            0.127065               0.690          [torch.Size([4, 8, 258, 258]), torch.Size([4, 8, 256, 256]), [1, 1, 1, 1]]
SUCCESS               0.087639            0.144981               0.604          [torch.Size([4, 8, 263, 259]), torch.Size([4, 8, 256, 256]), [1, 2, 3, 4]]
SUCCESS               0.088616            0.145363               0.610          [torch.Size([4, 8, 259, 259]), torch.Size([4, 8, 256, 256]), [3, 0, 0, 3]]
SUCCESS               0.087898            0.143081               0.614          [torch.Size([4, 8, 260, 260]), torch.Size([4, 8, 256, 256]), [2, 2, 2, 2]]
SUCCESS               0.519615            0.432856               1.200          [torch.Size([8, 64, 130, 130]), torch.Size([8, 64, 128, 128]), [1, 1, 1, 1]]
SUCCESS               0.520043            0.490100               1.061          [torch.Size([8, 64, 135, 131]), torch.Size([8, 64, 128, 128]), [1, 2, 3, 4]]
SUCCESS               0.521318            0.165108               3.157          [torch.Size([8, 64, 131, 131]), torch.Size([8, 64, 128, 128]), [3, 0, 0, 3]]
SUCCESS               0.517832            0.490873               1.055          [torch.Size([8, 64, 132, 132]), torch.Size([8, 64, 128, 128]), [2, 2, 2, 2]]
SUCCESS              22.147179            7.534192               2.940          [torch.Size([8, 128, 1026, 1026]), torch.Size([8, 128, 1024, 1024]), [1, 1, 1, 1]]
SUCCESS              22.298336            8.439931               2.642          [torch.Size([8, 128, 1031, 1027]), torch.Size([8, 128, 1024, 1024]), [1, 2, 3, 4]]
SUCCESS              22.165835            5.236162               4.233          [torch.Size([8, 128, 1027, 1027]), torch.Size([8, 128, 1024, 1024]), [3, 0, 0, 3]]
SUCCESS              22.274733            8.730151               2.551          [torch.Size([8, 128, 1028, 1028]), torch.Size([8, 128, 1024, 1024]), [2, 2, 2, 2]]
SUCCESS               0.043620            0.160656               0.272          [torch.Size([3, 130, 130]), torch.Size([3, 128, 128]), [1, 1, 1, 1]]
SUCCESS               0.042889            0.141118               0.304          [torch.Size([3, 135, 131]), torch.Size([3, 128, 128]), [1, 2, 3, 4]]
SUCCESS               0.043439            0.140343               0.310          [torch.Size([3, 131, 131]), torch.Size([3, 128, 128]), [3, 0, 0, 3]]
SUCCESS               0.042875            0.142937               0.300          [torch.Size([3, 132, 132]), torch.Size([3, 128, 128]), [2, 2, 2, 2]]
SUCCESS               0.025585            0.136344               0.188          [torch.Size([1, 32, 3, 130]), torch.Size([1, 32, 1, 128]), [1, 1, 1, 1]]
SUCCESS               0.026127            0.128818               0.203          [torch.Size([1, 32, 8, 131]), torch.Size([1, 32, 1, 128]), [1, 2, 3, 4]]
SUCCESS               0.026362            0.131461               0.201          [torch.Size([1, 32, 4, 131]), torch.Size([1, 32, 1, 128]), [3, 0, 0, 3]]
SUCCESS               0.025324            0.129193               0.196          [torch.Size([1, 32, 5, 132]), torch.Size([1, 32, 1, 128]), [2, 2, 2, 2]]

@Willing2329
Willing2329 force-pushed the add_replication_pad2d_backward_ascend branch from 9fe6aef to 2949cf8 Compare August 15, 2026 10:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant