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

Update transformer_engine._convert_model to skip LoRA layers #1766

Merged
merged 1 commit into from
Feb 18, 2025

Conversation

vivekgoe
Copy link
Collaborator

This PR updates transformer_enginer._convert_model() function such that lora-A, lora-B linear layers are skipped by TE. This has no impact on device time because these layers translate into small GEMMs whereas it helps in reducing host time by getting rid of TE host overhead.

…ers (#133)

* Update transformer_engine._convert_model to skip LoRA layers

* Remove print statement

* Add check for peft module availability
@HuggingFaceDocBuilderDev

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

@vivekgoe vivekgoe added synapse1.20 run-test Run CI for PRs from external contributors and removed synapse 1.21 labels Feb 18, 2025
@vivekgoe
Copy link
Collaborator Author

@regisss @libinta please help review and merge this PR.

Copy link
Collaborator

@regisss regisss left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@regisss regisss merged commit 21a5495 into huggingface:main Feb 18, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
run-test Run CI for PRs from external contributors synapse1.20
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants