Langchain-Chatchat
Langchain-Chatchat copied to clipboard
在启动项目的时候如何使用到多张gpu啊?
在启动项目的时候如何使用到多张gpu啊?
启动时如果判断torch.cuda.is_available返回为Ture且有多卡会自动把模型分配在多卡中运行
vicuna使用本地模型启动,单卡没问题,双卡就出现 ValueError: The device_map provided does not give any device for the following parameters: model.embed_tokens.weight, model.layers.0.self_attn.q_proj.weight,
启动时如果判断torch.cuda.is_available返回为Ture且有多卡会自动把模型分配在多卡中运行
启动时如果判断torch.cuda.is_available返回为Ture且有多卡会自动把模型分配在多卡中运行
https://github.com/imClumsyPanda/langchain-ChatGLM/commit/33bbb4779e373602cb8cfa984b2e4e8342f62a75 这个commit把chatglm_llm.py多卡部署的代码删了
vicuna使用本地模型启动,单卡没问题,双卡就出现 ValueError: The device_map provided does not give any device for the following parameters: model.embed_tokens.weight, model.layers.0.self_attn.q_proj.weight,
启动时如果判断torch.cuda.is_available返回为Ture且有多卡会自动把模型分配在多卡中运行
@elven2016 请问这个问题解决了吗