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

SmoothQuant高效平滑量化 #156

Open
ziwang-com opened this issue Jun 21, 2023 · 0 comments
Open

SmoothQuant高效平滑量化 #156

ziwang-com opened this issue Jun 21, 2023 · 0 comments

Comments

@ziwang-com
Copy link
Owner

https://github.com/leliyliu/smoothquant

SmoothQuant:针对大型语言模型的准确高效的训练后量化 [论文] [幻灯片]
如果您有兴趣获得更新,请在此处注册以获取通知!

image

intuition

抽象
大型语言模型 (LLM) 具有出色的性能,但会占用大量计算和内存。量化可以减少内存并加速推理。但是,对于超过1000亿个参数的LLM,现有方法无法保持准确性或无法在硬件上高效运行。我们提出了 SmoothQuant,这是一种免训练、精度保持和通用的训练后量化 (PTQ) 解决方案,可为 LLM 启用 8 位权重、8 位激活 (W8A8) 量化。 基于权重易于量化而激活不容易量化的事实,SmoothQuant 通过离线将量化难度从激活迁移到具有数学等效变换的权重来平滑激活异常值。SmoothQuant 能够对 LLM 中所有矩阵乘法的权重和激活进行 INT8 量化,包括 OPT-175B、BLOOM-176B、GLM-130B 和 MT-NLG 530B。SmoothQuant具有比现有技术更好的硬件效率。我们演示了 LLM 高达 1.56 倍的加速和 2 倍的内存减少,精度损失可以忽略不计。我们将SmoothQuant集成到FasterTransformer中,这是一个最先进的LLM服务框架,与FP16相比,GPU数量减少了一半,实现了更快的推理速度,从而可以在单个节点内提供530B LLM。我们的工作提供了一个交钥匙解决方案,可以降低硬件成本并使LLM民主化。

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

No branches or pull requests

1 participant