fix break for ckpt without _tp_plan (#39658)
* fix break for ckpt without _tp_plan
* Update src/transformers/modeling_utils.py
* Update src/transformers/modeling_utils.py
---------
Co-authored-by: wangzhengtao <wangzhengtao@msh.team>
Co-authored-by: Arthur <48595927+ArthurZucker@users.noreply.github.com>