xtuner
xtuner copied to clipboard
An efficient, flexible and full-featured toolkit for fine-tuning LLM (InternLM2, Llama3, Phi3, Qwen, Mistral, ...)
请问我在训练模型的时候,我想分别测试epoch为5和10的效果,可以只训练为10的时候吗,就是epoch为10是不是能包含5的情况呀,输出的权重文件是不是有对应5的时候
I try to load pretrained pth of llava: hub/llava-phi-3-mini-pth/model.pth. And I got this strange error: - used deepspeed zerospeed3 and flash-attn. ``` RuntimeError: Error(s) in loading state_dict for LLaVAModel: size...
在运行 4 节点 32卡的 LLaVA-InternLM2-20B 的预训练时,每次到eval阶段除master节点之外都会报错 FileNotExist,经过阅读 xtuner 和 mmengine 的代码后定位到问题: mmengine在多节点训练时,默认只在master节点保存log/vis_data等信息,这会导致worker节点的没有 vis_data 这个文件夹,但是 xtuner 在保存eval结果的时候是每个节点都保存一份,而且在打开文件的时候没有做父文件夹是否存在的验证,因此导致了除master节点外都因为文件夹不存在而挂掉。。。 修复方式也很简单:保证只在master节点存储结果(利用mmengine提供的 `master_only` 装饰器),每次保存前利用mmengine提供的接口 `mkdir_or_exist` 进行文件夹存在性检查。
hi, after I created the conda env, I run the experiments, I met the follwoing warning. I wonder does this affect my training and final result. thx.
I have a model of lava-Llama 3-8b-v1_1-hf format How do I run xtuner mmbench on a model in xtuner/ lava-Llama 3-8b-v1_1-hf format? Now it can only accept models in the...
多卡微调报错
单卡qlora微调可正常启动;多卡启动报错: 
权重载入
发现一个问题,因为微调为保存得到的是pt, 然后使用pth_to_hf后,保存为safetensor的形式,再多卡测试时载入,发现显存占用超过80g,但是将其保存为bin形式,每张卡显存均保持在30g,这是为什么呢,能否转换为hf的时候直接变成bin呢
1. **support plan** when it will release the version for supporting llava-llama3-70b? meainwhile, will it will consider of supporting unofficial version like, using llm of llama3-120b? huggingface link: [mlabonne/Meta-Llama-3-120B-Instruct](https://huggingface.co/mlabonne/Meta-Llama-3-120B-Instruct) 2....
> 执行脚本:qwen1_5_14b_chat_qlora_alpaca_e3 数据集:tatsu-lab/alpaca 获取数据集到本地的代码: ``` from datasets import load_dataset import json # 载入数据集 dataset = load_dataset("tatsu-lab/alpaca") # 假设我们只处理训练集部分 data = dataset['train'] # 将数据保存为 JSONL 文件 with open('/home/tangshi/TangShi/Pku政务大模型/Trainer/Tools/xtuner/data/alpaca_train.jsonl', 'w', encoding='utf-8') as...
求助关于显存的问题,我用xtuner的qlora配置用24G的显存是可以执行微调的,但是我希望尝试不量化的lora微调就是把关于量化的配置删掉后显示lora微调的显存不够是为什么呀,我采用chatglm3的官方lora微调24G是够的呀,后来我尝试利用双卡微调也是显示不够,是不是双卡不能叠加GPU而是只能加快速度呀,求助前辈们应该如何进行不量化的lora呢