mirror of
https://github.com/huggingface/transformers.git
synced 2025-08-02 03:01:07 +06:00
Add return type annotation to PreTrainedModel.from_pretrained (#31869)
Update modeling_utils.py Add return type annotation to PreTrainedModel.from_pretrained
This commit is contained in:
parent
6e59b30841
commit
c5bc2d5fd5
@ -2832,7 +2832,7 @@ class PreTrainedModel(nn.Module, ModuleUtilsMixin, GenerationMixin, PushToHubMix
|
||||
revision: str = "main",
|
||||
use_safetensors: bool = None,
|
||||
**kwargs,
|
||||
):
|
||||
) -> "PreTrainedModel":
|
||||
r"""
|
||||
Instantiate a pretrained pytorch model from a pre-trained model configuration.
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user