From 83e4364fbd921ad4fe808d31eb107ef080228a7a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Quentin=20Gallou=C3=A9dec?= <45557362+qgallouedec@users.noreply.github.com> Date: Wed, 20 Nov 2024 02:04:47 +0100 Subject: [PATCH] Use `json_schema_extra` instead of extra keyword in `Field` (#6764) > Using extra keyword arguments on `Field` is deprecated and will be removed. Use `json_schema_extra` instead. (Extra keys: 'new_param'). Deprecated in Pydantic V2.0 to be removed in V3.0. See Pydantic V2 Migration Guide at https://errors.pydantic.dev/2.9/migration/ Co-authored-by: Logan Adams <114770087+loadams@users.noreply.github.com> --- deepspeed/runtime/zero/config.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/deepspeed/runtime/zero/config.py b/deepspeed/runtime/zero/config.py index 7cac7e3c1ce7..19b272ce9e92 100644 --- a/deepspeed/runtime/zero/config.py +++ b/deepspeed/runtime/zero/config.py @@ -311,7 +311,7 @@ class DeepSpeedZeroConfig(DeepSpeedConfigModel): for efficient all_2_all_reduce comm """ - mics_shard_size: int = Field(-1, new_param="mics_shard_size") + mics_shard_size: int = Field(-1, json_schema_extra={"new_param": "mics_shard_size"}) mics_hierarchical_params_gather: bool = False