Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

optimize qwen2 memory usage again #11520

Merged

Conversation

MeouSker77
Copy link
Contributor

Description

attention_mask is not required when using sdp_causal and batch_size=1 or generating 2nd+ token, so don't generate it in these cases to save memory

@MeouSker77 MeouSker77 requested a review from rnwang04 July 5, 2024 08:54
@MeouSker77
Copy link
Contributor Author

@MeouSker77 MeouSker77 merged commit 7cb09a8 into intel-analytics:main Jul 5, 2024
1 check passed
@MeouSker77 MeouSker77 deleted the optimize-qwen2-mem-again branch July 5, 2024 09:32
RyuKosei pushed a commit to RyuKosei/ipex-llm that referenced this pull request Jul 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants