ggerganov / llama.cpp

LLM inference in C/C++
MIT License
65.16k stars 9.34k forks source link

bf16 support #6830

Closed ryao closed 5 months ago

ryao commented 5 months ago

Prerequisites

Please answer the following questions for yourself before submitting an issue.

Feature Description

It would be nice if llama.cpp supported bf16 in convert.py, main, and quantize.

Motivation

There are a few motivations:

Possible Implementation

I assume this is straightforward in theory, although I am not familiar with the codebase to be able to implement it myself.

Addendum

I actually did search rather than merely check boxes. The most relevant existing issue was #6125 asking about bf16 support in convert.py.

As for discussions, I did not find anything particularly relevant, although one discussion on convert.py looked superficially relevant until I read it in detail.

sorasoras commented 5 months ago

https://github.com/ggerganov/llama.cpp/pull/6412

ryao commented 5 months ago

@sorasoras This is what I get for searching for bf16 instead of bfloat16. Thanks.