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

[LLM] fix bug when loss is None in llama modeling.py #8459

Merged
merged 1 commit into from
May 22, 2024

Conversation

cqulilujia
Copy link
Contributor

@cqulilujia cqulilujia commented May 17, 2024

PR types

Bug Fixs

PR changes

Models

Description

修复llama模型在训练过程中由异常数据导致的loss为None时引发的异常, #8342 中考虑到了这一问题,但loss设置为了float而非tensor形式。
另可参考: #8348 #8299

Copy link

paddle-bot bot commented May 17, 2024

Thanks for your contribution!

Copy link

codecov bot commented May 17, 2024

Codecov Report

Attention: Patch coverage is 0% with 4 lines in your changes are missing coverage. Please review.

Project coverage is 54.29%. Comparing base (87e4c4f) to head (e1d30a0).

Files Patch % Lines
paddlenlp/transformers/llama/modeling.py 0.00% 4 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #8459      +/-   ##
===========================================
- Coverage    54.29%   54.29%   -0.01%     
===========================================
  Files          617      617              
  Lines        96339    96341       +2     
===========================================
- Hits         52312    52308       -4     
- Misses       44027    44033       +6     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@cqulilujia
Copy link
Contributor Author

@ZHUI 麻烦帮忙review

Copy link
Collaborator

@ZHUI ZHUI left a comment

Choose a reason for hiding this comment

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

LGTM

@wawltor wawltor merged commit 70bffa8 into PaddlePaddle:develop May 22, 2024
8 of 12 checks passed
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

3 participants