peft icon indicating copy to clipboard operation
peft copied to clipboard

try to fix Zero3 Memory Leak following @tohtana idea

Open dumpmemory opened this issue 1 year ago • 1 comments

here i am following @tohtana 's modification from https://github.com/microsoft/DeepSpeed/issues/3002 to fix https://github.com/huggingface/peft/issues/161 . it worked with deepspeed 0.9.1 and torch 2.0. Thanks for @tohtana 's help.

dumpmemory avatar Apr 24 '23 06:04 dumpmemory

The documentation is not available anymore as the PR was closed or merged.

When will this be deployed?

aashay96 avatar Apr 26 '23 21:04 aashay96

Hello @dumpmemory, great work getting this issue solved from DeepSpeed and raising the fix here. Could you apply the fix to all places in lora and adalora wherein F.linear is being used . That would solve the issue in all places

cool i will. Thanks

dumpmemory avatar Apr 28 '23 02:04 dumpmemory

@pacman100 pls help me to check it. i have made all F.linear replaced.

dumpmemory avatar Apr 28 '23 02:04 dumpmemory

Thank you @dumpmemory for iterating, LGTM! 🤗

Could you run make style and make quality to fix the quality issues?

yes, i will. I will also test new commits from deepspeed sides. Thanks again.

dumpmemory avatar May 05 '23 01:05 dumpmemory

Hello, @dumpmemory, there are still some code quality issues. Please resolve them to go ahead with the PR

pacman100 avatar May 10 '23 04:05 pacman100

Hello, is this PR still required? As the DeepSpeed team fixed it in their codebase

pacman100 avatar May 10 '23 06:05 pacman100

this pr is no longer required.

dumpmemory avatar May 10 '23 06:05 dumpmemory