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

This change adds support for Intel Gaudi HPUs. #7275

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

emascarenhas
Copy link

Several configuration files are provided in the examples directory for use with Gaudi.

LLaMA-Factory features and optimizations including inferencing, training (sft, dpo, etc.), LoRA fine-tuning, distributed training with DeepSpeed and DDP are working. Please see README for details. Co-authored-by: Yaser Afshar [email protected] Co-authored-by: Edward Mascarenhas [email protected] Co-authored-by: Jianhong-Zhang [email protected] Co-authored-by: Wenbin Chen [email protected]
Co-authored-by: Voas, Tanner [email protected]

Before submitting

	Several configuration files are provided in the examples directory for use with Gaudi.
LLaMA-Factory features and optimizations including inferencing, training (sft, dpo, etc.), LoRA
fine-tuning, distributed training with DeepSpeed and DDP are working. Please see README for details.
Co-authored-by: Yaser Afshar [email protected]
Co-authored-by: Edward Mascarenhas [email protected]
Co-authored-by: Jianhong-Zhang [email protected]
Co-authored-by: Wenbin Chen [email protected]
Co-authored-by: Voas, Tanner [email protected]
Copy link
Owner

@hiyouga hiyouga left a comment

Choose a reason for hiding this comment

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

Thanks for your contribution, please view the comments

Copy link
Owner

Choose a reason for hiding this comment

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

Could we avoid add too many examples? I think one for fine-tuning and another one for inference is sufficient

Copy link
Author

Choose a reason for hiding this comment

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

Thanks for your comment. Yes we can. I will remove following files from examples.
deleted: examples/inference/llama3_gaudi.yaml
deleted: examples/train_full/llama3_full_sft_ds3_gaudi.yaml
deleted: examples/train_full/qwen2_full_sft_ds1_gaudi.yaml
deleted: examples/train_full/qwen2_full_sft_ds3_gaudi.yaml
deleted: examples/train_lora/llama3_lora_dpo_gaudi.yaml
deleted: examples/train_lora/llama3_lora_eval_gaudi.yaml
deleted: examples/train_lora/llama3_lora_ppo_gaudi.yaml
deleted: examples/train_lora/llama3_lora_pretrain_gaudi.yaml
deleted: examples/train_lora/llama3_lora_reward_gaudi.yaml

Only remaining will be 1 file in inference, and 3 in train_lora for llama3 with deepspeed and without deepspeed, and qwen2vl.

Copy link
Author

Choose a reason for hiding this comment

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

requirements.txt Outdated
@@ -1,7 +1,6 @@
transformers>=4.41.2,<=4.49.0,!=4.46.*,!=4.47.*,!=4.48.*;python_version<'3.10'
Copy link
Owner

Choose a reason for hiding this comment

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

Transformers 4.49 is required. We should not downgrade the version

Copy link
Author

@emascarenhas emascarenhas Mar 12, 2025

Choose a reason for hiding this comment

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

Ok. I reverted to existing requirements.txt file and fixed the requirements-gaudi.txt file. We expect in about a months time to support transformers 4.49.2 with Gaudi as well at which point we may not need requirements-gaudi.txt. a0f1661 and a16e3d4

@hiyouga hiyouga added the pending This problem is yet to be addressed label Mar 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pending This problem is yet to be addressed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants