fix: hfdeepspeed config argument (#15711)

`HfDeepSpeedConfig` accepts a dictionary or path to `.json` file containing DS configurations, not `TrainingArguments`.
This commit is contained in:
Jake Tae 2022-02-18 12:00:02 -05:00 committed by GitHub
parent 83f45cd656
commit 3de12906c8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -971,7 +971,7 @@ class Trainer:
# Rebuild the deepspeed config to reflect the updated training parameters
from transformers.deepspeed import HfDeepSpeedConfig
self.args.hf_deepspeed_config = HfDeepSpeedConfig(self.args)
self.args.hf_deepspeed_config = HfDeepSpeedConfig(self.args.deepspeed)
def _report_to_hp_search(
self, trial: Union["optuna.Trial", Dict[str, Any]], epoch: int, metrics: Dict[str, float]