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

convert : use f32 outtype for bf16 tensors #6106

Merged
merged 1 commit into from
Mar 18, 2024

Conversation

Artefact2
Copy link
Collaborator

@Artefact2 Artefact2 commented Mar 16, 2024

The old behaviour is to use f16, but bf16 to f16 is not a lossless conversion. Change the outtype to f32 to default to a lossless conversion.

This restores original intended behaviour of #1309.

The old behaviour is to use f16, but bf16 to f16 is not a lossless conversion.
Change the outtype to f32 to default to a lossless conversion.
@cebtenzzre
Copy link
Collaborator

This was originally changed in commit 3839704, which was part of #2635 which was merged into #2398.

@ggerganov ggerganov merged commit 3a6efdd into ggerganov:master Mar 18, 2024
11 of 22 checks passed
@cebtenzzre cebtenzzre removed the request for review from ivanstepanovftw March 18, 2024 16:29
hodlen pushed a commit to hodlen/llama.cpp that referenced this pull request Apr 1, 2024
The old behaviour is to use f16, but bf16 to f16 is not a lossless conversion.
Change the outtype to f32 to default to a lossless conversion.
hodlen pushed a commit to hodlen/llama.cpp that referenced this pull request Apr 3, 2024
The old behaviour is to use f16, but bf16 to f16 is not a lossless conversion.
Change the outtype to f32 to default to a lossless conversion.
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.

3 participants