You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
学生党在colab上尝试了您的代码 但是显存只有15G 没法load这个6B的模型。
我把代码中的chatGLM-6B替换成chatGLM-6B-int4 想看看能否微调
但是 trainer.train()那里一直报错 self and mat2 must have same dtype
我怀疑可能是模型经过量化后其参数的精度和batch输入精度不匹配。
想请教您,如何修改代码,实现在量化后的小模型chatGLM-6B-int4上微调。
非常感谢!
Activity
thaumstrial commentedon Mar 24, 2023
由于peft并不支持int4,所以无法使用。至于如何修改代码,我也尝试过模仿int8加载那样,直接在peft源代码上加入对int4的支持,但没花太多时间研究,没有成功。
可以参考这个issue修改peft的源代码
我当前正常尝试对模型剪枝,或许能降低显存开销。
valkryhx commentedon Mar 24, 2023
感谢!我来研究研究这个issue