We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5c482b6 commit 0c3c165Copy full SHA for 0c3c165
paddlenlp/transformers/utils.py
@@ -850,6 +850,8 @@ def dtype_byte_size(dtype):
850
"""
851
if dtype == paddle.bool:
852
return 1 / 8
853
+ if dtype == paddle.float8_e4m3fn or dtype == paddle.float8_e5m2:
854
+ return 1
855
bit_search = re.search(r"[^\d](\d+)$", str(dtype))
856
if bit_search is None:
857
raise ValueError(f"`dtype` is not a valid dtype: {dtype}.")
0 commit comments