PaddleNLP icon indicating copy to clipboard operation
PaddleNLP copied to clipboard

[AMP] add auto cast in init parameters

Open BeingGod opened this issue 1 year ago • 4 comments

PR types

New features

PR changes

Others

Description

In amp O2 level, some op may not have fp16 kernel (etc. gaussian). It will cause weight set_value failure due to dtype not match. It can solve by adding amp auto cast in init parameters.

image

BeingGod avatar Jan 25 '24 07:01 BeingGod

Codecov Report

Attention: Patch coverage is 66.66667% with 2 lines in your changes missing coverage. Please review.

Project coverage is 56.68%. Comparing base (c1ccafa) to head (396012e). Report is 447 commits behind head on develop.

Files Patch % Lines
paddlenlp/transformers/model_utils.py 66.66% 2 Missing :warning:
Additional details and impacted files
@@            Coverage Diff            @@
##           develop    #7899    +/-   ##
=========================================
  Coverage    56.67%   56.68%            
=========================================
  Files          588      588            
  Lines        89243    89356   +113     
=========================================
+ Hits         50580    50651    +71     
- Misses       38663    38705    +42     

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

codecov[bot] avatar Jan 25 '24 08:01 codecov[bot]

This Pull Request is stale because it has been open for 60 days with no activity. 当前Pull Request 60天内无活动,被标记为stale。

github-actions[bot] avatar Apr 27 '24 00:04 github-actions[bot]

This Pull Request is stale because it has been open for 60 days with no activity. 当前Pull Request 60天内无活动,被标记为stale。

github-actions[bot] avatar Jun 28 '24 00:06 github-actions[bot]

This Pull Request is stale because it has been open for 60 days with no activity. 当前Pull Request 60天内无活动,被标记为stale。

github-actions[bot] avatar Aug 28 '24 00:08 github-actions[bot]