FastChat icon indicating copy to clipboard operation
FastChat copied to clipboard

Can I finetune the 7B model by using 8*3090 GPU ?

Open lxy2017 opened this issue 2 years ago • 2 comments

lxy2017 avatar May 05 '23 09:05 lxy2017

The answer is yes. but training is very slow and the max length should less than 512 (512 with fp16 and lora r=8 will OOM)

Based on my own testing, I recommend disabling flash_attention as they haven't fixed the sm86 bug of rtx3090 in the backward phase with hidden dim 128. Additionally, I found that using a max length of 256 worked better for me than the previously recommended max length of 512. I hope this information is helpful to others who may be experiencing similar issues.

ericzhou571 avatar May 05 '23 13:05 ericzhou571

Thank you for your answer.

lxy2017 avatar May 06 '23 02:05 lxy2017

@ericzhou571 I try to finetune the 7B model by using 4*3090 GPU and I set batch size to 1 and max length to 256. However, I still got OOM. Could you please tell me more about how you finetune the 7B model (parameters or other optimizations)?

beerde avatar Jul 15 '23 11:07 beerde