Skip to content

Conversation

@zrr1999
Copy link
Member

@zrr1999 zrr1999 commented Nov 3, 2025

PR Category

Operator Mechanism

PR Types

Bug fixes

Description

Pcard-89071

bert 单测中网络初始化时,由于 XavierUniform 强制设置了seed=0,导致不同硬件出现不同的结果。
通过将 seed设置为114, 不同显卡结果一致,所以可以确定loss不同的原因是seed=0时,不同 gpu 下有不同的随机结果。
本PR修改后,通过判断硬件类型确定target。

@paddle-bot
Copy link

paddle-bot bot commented Nov 3, 2025

你的PR提交成功,感谢你对开源项目的贡献!
请关注后续CI自动化测试结果,详情请参考Paddle-CI手册
Your PR has been submitted. Thanks for your contribution!
Please wait for the result of CI firstly. See Paddle CI Manual for details.

@tianshuo78520a tianshuo78520a merged commit 542184a into PaddlePaddle:develop Nov 5, 2025
74 of 75 checks passed
AlAuAu pushed a commit to AlAuAu/Paddle that referenced this pull request Nov 6, 2025
* fix test_bert_prim.py

* fix

* fix
Manfredss pushed a commit to Manfredss/PaddleDebug that referenced this pull request Nov 7, 2025
* fix test_bert_prim.py

* fix

* fix
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants