Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

【Fix PIR JIT SaveLoad Unittest No.18】modify test_bert.py #64151

Merged
merged 2 commits into from
May 10, 2024

Conversation

xiaoguoguo626807
Copy link
Contributor

@xiaoguoguo626807 xiaoguoguo626807 commented May 9, 2024

PR Category

others

PR Types

others

Description

pcard-67164

修复test_bert.py 中使用jit.save 保存, load_inference_model 加载的若干问题:

  1. 修改了传入的model文件后缀解决反序列化program的报错。
  2. 修改了load_vars_pir 中当scope 里没有相应名字的varible时创建一个,解决找不到variable的问题。
  3. 修改了load_pir_infence_modle 中返回feed_name,fetch_var的代码,由于执行器会给传入的fetch_var再加fetch,导致program 中出现相同col 的两套fetch.

TODO:
目前推理的predictor 未开发完成 predict_analysis_inference 函数在pir模式下跳过;
bert load 回的program和动态图load 的结果精度为e-4, 查看load 的参数与旧IR一致,待查验精度diff的原因。#64168

Related links

Copy link

paddle-bot bot commented May 9, 2024

你的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.

Copy link
Contributor

@changeyoung98 changeyoung98 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@xiaoguoguo626807 xiaoguoguo626807 merged commit 87d19a2 into PaddlePaddle:develop May 10, 2024
30 of 31 checks passed
@xiaoguoguo626807 xiaoguoguo626807 deleted the test_bert branch May 10, 2024 03:06
co63oc pushed a commit to co63oc/Paddle that referenced this pull request May 11, 2024
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.

None yet

2 participants