[docs] Fix doc format (#28684)

* fix hfoptions

* revert changes to other files

* fix
This commit is contained in:
Steven Liu 2024-01-24 11:18:59 -08:00 committed by GitHub
parent 8278b1538e
commit f40b87de0c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -956,6 +956,8 @@ engine = deepspeed.initialize(model=model, config_params=ds_config, ...)
</hfoption>
<hfoption id="non-pretrained model">
[`HfDeepSpeedConfig`] is not required for ZeRO-1 or ZeRO-2.
```py
from transformers.integrations import HfDeepSpeedConfig
from transformers import AutoModel, AutoConfig
@ -969,7 +971,8 @@ model = AutoModel.from_config(config)
engine = deepspeed.initialize(model=model, config_params=ds_config, ...)
```
[`HfDeepSpeedConfig`] is not required for ZeRO-1 or ZeRO-2.
</hfoption>
</hfoptions>
### Non-Trainer ZeRO Inference