CARVIEW |
Select Language
HTTP/2 200
date: Sun, 27 Jul 2025 17:45:47 GMT
content-type: text/html; charset=utf-8
vary: X-PJAX, X-PJAX-Container, Turbo-Visit, Turbo-Frame, X-Requested-With,Accept-Encoding, Accept, X-Requested-With
x-repository-download: git clone https://github.com/PaddlePaddle/Paddle.git
etag: W/"b62d712179410a6ae1aa30e6f4b6484f"
cache-control: max-age=0, private, must-revalidate
strict-transport-security: max-age=31536000; includeSubdomains; preload
x-frame-options: deny
x-content-type-options: nosniff
x-xss-protection: 0
referrer-policy: no-referrer-when-downgrade
content-security-policy: default-src 'none'; base-uri 'self'; child-src github.githubassets.com github.com/assets-cdn/worker/ github.com/assets/ gist.github.com/assets-cdn/worker/; connect-src 'self' uploads.github.com www.githubstatus.com collector.github.com raw.githubusercontent.com api.github.com github-cloud.s3.amazonaws.com github-production-repository-file-5c1aeb.s3.amazonaws.com github-production-upload-manifest-file-7fdce7.s3.amazonaws.com github-production-user-asset-6210df.s3.amazonaws.com *.rel.tunnels.api.visualstudio.com wss://*.rel.tunnels.api.visualstudio.com objects-origin.githubusercontent.com copilot-proxy.githubusercontent.com proxy.individual.githubcopilot.com proxy.business.githubcopilot.com proxy.enterprise.githubcopilot.com *.actions.githubusercontent.com wss://*.actions.githubusercontent.com productionresultssa0.blob.core.windows.net/ productionresultssa1.blob.core.windows.net/ productionresultssa2.blob.core.windows.net/ productionresultssa3.blob.core.windows.net/ productionresultssa4.blob.core.windows.net/ productionresultssa5.blob.core.windows.net/ productionresultssa6.blob.core.windows.net/ productionresultssa7.blob.core.windows.net/ productionresultssa8.blob.core.windows.net/ productionresultssa9.blob.core.windows.net/ productionresultssa10.blob.core.windows.net/ productionresultssa11.blob.core.windows.net/ productionresultssa12.blob.core.windows.net/ productionresultssa13.blob.core.windows.net/ productionresultssa14.blob.core.windows.net/ productionresultssa15.blob.core.windows.net/ productionresultssa16.blob.core.windows.net/ productionresultssa17.blob.core.windows.net/ productionresultssa18.blob.core.windows.net/ productionresultssa19.blob.core.windows.net/ github-production-repository-image-32fea6.s3.amazonaws.com github-production-release-asset-2e65be.s3.amazonaws.com insights.github.com wss://alive.github.com api.githubcopilot.com api.individual.githubcopilot.com api.business.githubcopilot.com api.enterprise.githubcopilot.com; font-src github.githubassets.com; form-action 'self' github.com gist.github.com copilot-workspace.githubnext.com objects-origin.githubusercontent.com; frame-ancestors 'none'; frame-src viewscreen.githubusercontent.com notebooks.githubusercontent.com; img-src 'self' data: blob: github.githubassets.com media.githubusercontent.com camo.githubusercontent.com identicons.github.com avatars.githubusercontent.com private-avatars.githubusercontent.com github-cloud.s3.amazonaws.com objects.githubusercontent.com release-assets.githubusercontent.com secured-user-images.githubusercontent.com/ user-images.githubusercontent.com/ private-user-images.githubusercontent.com opengraph.githubassets.com copilotprodattachments.blob.core.windows.net/github-production-copilot-attachments/ github-production-user-asset-6210df.s3.amazonaws.com customer-stories-feed.github.com spotlights-feed.github.com objects-origin.githubusercontent.com *.githubusercontent.com; manifest-src 'self'; media-src github.com user-images.githubusercontent.com/ secured-user-images.githubusercontent.com/ private-user-images.githubusercontent.com github-production-user-asset-6210df.s3.amazonaws.com gist.github.com; script-src github.githubassets.com; style-src 'unsafe-inline' github.githubassets.com; upgrade-insecure-requests; worker-src github.githubassets.com github.com/assets-cdn/worker/ github.com/assets/ gist.github.com/assets-cdn/worker/
server: github.com
content-encoding: gzip
accept-ranges: bytes
set-cookie: _gh_sess=3yTrpSIDBtr36HtW0yKIc6lNUaCGTKceqqXdGAR3YG6YsrsLNnuc4qW50a9q1X3BucrqpMT787e5hn8oTSJhsg4lZ1f7T1P8H%2Byqm3sDthB5dpKar7F47y5ipj0fZZKUm8pOr3M0TyYGJCChZDCmU7%2FIdku5ipDMbcSAq%2B8SEXMu0lqcmCyXVZkqVgQKDlwMiFaasp5E8lSXKQQwYIaZkLm7rL1M3ixeju8m6tkI0bUnRXTxyKbKNT1jZJSF9UdEWAeMcbSmJU1uMbO4Q7Mreg%3D%3D--RGEWyNhHfzMXlwaa--nnuaz52hNR9xaEupFOE3Rw%3D%3D; Path=/; HttpOnly; Secure; SameSite=Lax
set-cookie: _octo=GH1.1.35542464.1753638346; Path=/; Domain=github.com; Expires=Mon, 27 Jul 2026 17:45:46 GMT; Secure; SameSite=Lax
set-cookie: logged_in=no; Path=/; Domain=github.com; Expires=Mon, 27 Jul 2026 17:45:46 GMT; HttpOnly; Secure; SameSite=Lax
x-github-request-id: C300:3B05D7:1073114:15910E5:688665CA
【New IR】 backward gradients accumulate test and pulish append_backwar… · PaddlePaddle/Paddle@b157343 · GitHub




authored
Copy file name to clipboardExpand all lines: python/paddle/autograd/backward.py
Copy file name to clipboardExpand all lines: python/paddle/autograd/backward_utils.py
Skip to content
Navigation Menu
{{ message }}
-
Notifications
You must be signed in to change notification settings - Fork 5.8k
Commit b157343
【New IR】 backward gradients accumulate test and pulish append_backward_ops func for op_pattern (#56265)
* [prim][newir] add basic framework for primitive
* support desctensor in new ir
* add vjp interface
* support vjp in new ir
* support vjp in new ir
* polish vjp interface
* fix stop_gradients set
* fix vjp dispatch
* add comment
* add vjp test for new ir
* add test for tanh vjp
* [prim][newir] add basic framework for primitive
* support desctensor in new ir
* support vjp in new ir
* support vjp in new ir
* polish vjp interface
* fix stop_gradients set
* fix vjp dispatch
* add comment
* add vjp test for new ir
* add test for tanh vjp
* add eager and static backend for warp lower level api
* support call_vjp pybind
* polish code and add test for vjp
* remove useless code
* polish code
* remove useless code
* support mean vjp
* backward origin code
* add test for mean vjp and support has_vjp function
* fix call_vjp
* polish code
* add attrs and dtype interface
* add primitive ops set for backend
* fix compile bugs
* fix some bugs
* fix windows bugs
* add vjp test for tanh_
* fix inference CI
* fix inference ci
* modify fluid cmake
* origin test of tanh and mean passed
* fix conflict
* modify stop_gradient
* remove useless deps
* add cmake
* modify block.ops
* modify test
* fix conflict
* reply review comments
* reply review comments
* pulish code
* fix comment
* fix test
* polish code
* modify backward stop_gradients
* modify static_backend.cc
* refactor grad_op
* support add and add_inplace vjp
* remove useless code
* remove useless code
* remove cout
* modify add_n
* modify add_n with add_vjp test
* modify add_n with add_vjp test
* fix conflict and concat call_vjp
* modify backward test
* Add more gen api
---------
Co-authored-by: cxxly <chenxx_id@163.com>
Co-authored-by: Charles-hit <wanghao107@baidu.com>
Co-authored-by: zhangbo9674 <zhangbo54@baidu.com>
Co-authored-by: YuanRisheng <yuanrisheng@baidu.com>
Co-authored-by: 0x45f <wangzhen45@baidu.com>1 parent 920c66e commit b157343Copy full SHA for b157343
File tree
Expand file treeCollapse file tree
3 files changed
+218
-89
lines changedFilter options
- python/paddle/autograd
- test/ir/new_ir
Expand file treeCollapse file tree
3 files changed
+218
-89
lines changedpython/paddle/autograd/backward.py
Copy file name to clipboardExpand all lines: python/paddle/autograd/backward.py+161-53Lines changed: 161 additions & 53 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
181 | 181 |
| |
182 | 182 |
| |
183 | 183 |
| |
184 |
| - | |
185 | 184 |
| |
186 | 185 |
| |
187 | 186 |
| |
| |||
192 | 191 |
| |
193 | 192 |
| |
194 | 193 |
| |
195 |
| - | |
196 | 194 |
| |
197 | 195 |
| |
198 | 196 |
| |
| |||
313 | 311 |
| |
314 | 312 |
| |
315 | 313 |
| |
| 314 | + | |
| 315 | + | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
| 328 | + | |
| 329 | + | |
| 330 | + | |
| 331 | + | |
| 332 | + | |
| 333 | + | |
316 | 334 |
| |
317 | 335 |
| |
318 | 336 |
| |
319 | 337 |
| |
320 | 338 |
| |
321 | 339 |
| |
322 |
| - | |
323 |
| - | |
324 |
| - | |
325 |
| - | |
326 |
| - | |
327 |
| - | |
328 |
| - | |
329 |
| - | |
330 |
| - | |
331 |
| - | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
| 343 | + | |
| 344 | + | |
| 345 | + | |
| 346 | + | |
| 347 | + | |
| 348 | + | |
| 349 | + | |
| 350 | + | |
| 351 | + | |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
332 | 358 |
| |
333 | 359 |
| |
334 | 360 |
| |
335 | 361 |
| |
336 | 362 |
| |
337 | 363 |
| |
338 | 364 |
| |
339 |
| - | |
340 | 365 |
| |
341 | 366 |
| |
342 | 367 |
| |
| |||
347 | 372 |
| |
348 | 373 |
| |
349 | 374 |
| |
350 |
| - | |
351 | 375 |
| |
352 | 376 |
| |
353 |
| - | |
354 |
| - | |
355 |
| - | |
356 |
| - | |
| 377 | + | |
357 | 378 |
| |
358 |
| - | |
359 |
| - | |
360 |
| - | |
361 |
| - | |
362 |
| - | |
363 |
| - | |
364 |
| - | |
365 |
| - | |
366 |
| - | |
| 379 | + | |
| 380 | + | |
| 381 | + | |
| 382 | + | |
| 383 | + | |
| 384 | + | |
| 385 | + | |
| 386 | + | |
| 387 | + | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
| 391 | + | |
| 392 | + | |
| 393 | + | |
| 394 | + | |
| 395 | + | |
| 396 | + | |
| 397 | + | |
| 398 | + | |
| 399 | + | |
| 400 | + | |
| 401 | + | |
| 402 | + | |
| 403 | + | |
| 404 | + | |
| 405 | + | |
| 406 | + | |
| 407 | + | |
| 408 | + | |
| 409 | + | |
| 410 | + | |
| 411 | + | |
| 412 | + | |
| 413 | + | |
| 414 | + | |
| 415 | + | |
| 416 | + | |
| 417 | + | |
| 418 | + | |
| 419 | + | |
| 420 | + | |
| 421 | + | |
| 422 | + | |
| 423 | + | |
| 424 | + | |
| 425 | + | |
| 426 | + | |
| 427 | + | |
| 428 | + | |
| 429 | + | |
| 430 | + | |
| 431 | + | |
| 432 | + | |
| 433 | + | |
| 434 | + | |
| 435 | + | |
| 436 | + | |
| 437 | + | |
| 438 | + | |
| 439 | + | |
| 440 | + | |
| 441 | + | |
| 442 | + | |
| 443 | + | |
| 444 | + | |
| 445 | + | |
| 446 | + | |
| 447 | + | |
| 448 | + | |
| 449 | + | |
| 450 | + | |
| 451 | + | |
| 452 | + | |
| 453 | + | |
| 454 | + | |
| 455 | + | |
| 456 | + | |
| 457 | + | |
| 458 | + | |
| 459 | + | |
| 460 | + | |
| 461 | + | |
| 462 | + | |
| 463 | + | |
| 464 | + | |
| 465 | + | |
| 466 | + | |
367 | 467 |
| |
368 |
| - | |
| 468 | + | |
| 469 | + | |
| 470 | + | |
| 471 | + | |
369 | 472 |
| |
370 | 473 |
| |
371 | 474 |
| |
| |||
374 | 477 |
| |
375 | 478 |
| |
376 | 479 |
| |
377 |
| - | |
378 |
| - | |
379 |
| - | |
380 |
| - | |
381 |
| - | |
382 |
| - | |
| 480 | + | |
| 481 | + | |
| 482 | + | |
383 | 483 |
| |
| 484 | + | |
384 | 485 |
| |
385 |
| - | |
386 | 486 |
| |
387 | 487 |
| |
388 | 488 |
| |
389 | 489 |
| |
390 | 490 |
| |
391 |
| - | |
392 |
| - | |
| 491 | + | |
393 | 492 |
| |
394 |
| - | |
395 |
| - | |
396 |
| - | |
397 |
| - | |
398 |
| - | |
399 |
| - | |
400 |
| - | |
401 |
| - | |
402 | 493 |
| |
403 |
| - | |
| 494 | + | |
404 | 495 |
| |
405 | 496 |
| |
| 497 | + | |
| 498 | + | |
| 499 | + | |
406 | 500 |
| |
407 | 501 |
| |
408 | 502 |
| |
409 | 503 |
| |
410 | 504 |
| |
411 |
| - | |
| 505 | + | |
| 506 | + | |
| 507 | + | |
| 508 | + | |
| 509 | + | |
| 510 | + | |
| 511 | + | |
412 | 512 |
| |
| 513 | + | |
| 514 | + | |
| 515 | + | |
413 | 516 |
| |
414 | 517 |
| |
415 | 518 |
| |
| |||
441 | 544 |
| |
442 | 545 |
| |
443 | 546 |
| |
444 |
| - | |
| 547 | + | |
445 | 548 |
| |
446 | 549 |
| |
447 | 550 |
| |
| |||
457 | 560 |
| |
458 | 561 |
| |
459 | 562 |
| |
460 |
| - | |
461 |
| - | |
462 |
| - | |
463 |
| - | |
| 563 | + | |
| 564 | + | |
| 565 | + | |
| 566 | + | |
| 567 | + | |
| 568 | + | |
| 569 | + | |
| 570 | + | |
464 | 571 |
| |
465 | 572 |
| |
466 | 573 |
| |
| |||
500 | 607 |
| |
501 | 608 |
| |
502 | 609 |
| |
503 |
| - | |
504 | 610 |
| |
505 | 611 |
| |
506 | 612 |
| |
507 | 613 |
| |
508 | 614 |
| |
509 | 615 |
| |
| 616 | + | |
| 617 | + | |
510 | 618 |
| |
511 | 619 |
| |
512 | 620 |
| |
|
python/paddle/autograd/backward_utils.py
Copy file name to clipboardExpand all lines: python/paddle/autograd/backward_utils.py+5-1Lines changed: 5 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
7 | 7 |
| |
8 | 8 |
| |
9 | 9 |
| |
10 |
| - | |
| 10 | + | |
11 | 11 |
| |
12 | 12 |
| |
13 | 13 |
| |
| |||
37 | 37 |
| |
38 | 38 |
| |
39 | 39 |
| |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
40 | 44 |
| |
41 | 45 |
| |
42 | 46 |
| |
|
You can’t perform that action at this time.
0 commit comments