Unverified Commit 711d901c authored by qqaatw's avatar qqaatw Committed by GitHub
Browse files

Fix minor docstring typos. (#12682)

parent 90178b0c
...@@ -199,7 +199,7 @@ class FlaxPreTrainedModel(PushToHubMixin, FlaxGenerationMixin): ...@@ -199,7 +199,7 @@ class FlaxPreTrainedModel(PushToHubMixin, FlaxGenerationMixin):
from_pt (:obj:`bool`, `optional`, defaults to :obj:`False`): from_pt (:obj:`bool`, `optional`, defaults to :obj:`False`):
Load the model weights from a PyTorch checkpoint save file (see docstring of Load the model weights from a PyTorch checkpoint save file (see docstring of
``pretrained_model_name_or_path`` argument). ``pretrained_model_name_or_path`` argument).
ignore_mismatched_size (:obj:`bool`, `optional`, defaults to :obj:`False`): ignore_mismatched_sizes (:obj:`bool`, `optional`, defaults to :obj:`False`):
Whether or not to raise an error if some of the weights from the checkpoint do not have the same size Whether or not to raise an error if some of the weights from the checkpoint do not have the same size
as the weights of the model (if for instance, you are instantiating a model with 10 labels from a as the weights of the model (if for instance, you are instantiating a model with 10 labels from a
checkpoint with 3 labels). checkpoint with 3 labels).
......
...@@ -1132,7 +1132,7 @@ class TFPreTrainedModel(tf.keras.Model, TFModelUtilsMixin, TFGenerationMixin, Pu ...@@ -1132,7 +1132,7 @@ class TFPreTrainedModel(tf.keras.Model, TFModelUtilsMixin, TFGenerationMixin, Pu
from_pt: (:obj:`bool`, `optional`, defaults to :obj:`False`): from_pt: (:obj:`bool`, `optional`, defaults to :obj:`False`):
Load the model weights from a PyTorch state_dict save file (see docstring of Load the model weights from a PyTorch state_dict save file (see docstring of
``pretrained_model_name_or_path`` argument). ``pretrained_model_name_or_path`` argument).
ignore_mismatched_size (:obj:`bool`, `optional`, defaults to :obj:`False`): ignore_mismatched_sizes (:obj:`bool`, `optional`, defaults to :obj:`False`):
Whether or not to raise an error if some of the weights from the checkpoint do not have the same size Whether or not to raise an error if some of the weights from the checkpoint do not have the same size
as the weights of the model (if for instance, you are instantiating a model with 10 labels from a as the weights of the model (if for instance, you are instantiating a model with 10 labels from a
checkpoint with 3 labels). checkpoint with 3 labels).
......
...@@ -1037,7 +1037,7 @@ class PreTrainedModel(nn.Module, ModuleUtilsMixin, GenerationMixin, PushToHubMix ...@@ -1037,7 +1037,7 @@ class PreTrainedModel(nn.Module, ModuleUtilsMixin, GenerationMixin, PushToHubMix
from_flax (:obj:`bool`, `optional`, defaults to :obj:`False`): from_flax (:obj:`bool`, `optional`, defaults to :obj:`False`):
Load the model weights from a Flax checkpoint save file (see docstring of Load the model weights from a Flax checkpoint save file (see docstring of
``pretrained_model_name_or_path`` argument). ``pretrained_model_name_or_path`` argument).
ignore_mismatched_size (:obj:`bool`, `optional`, defaults to :obj:`False`): ignore_mismatched_sizes (:obj:`bool`, `optional`, defaults to :obj:`False`):
Whether or not to raise an error if some of the weights from the checkpoint do not have the same size Whether or not to raise an error if some of the weights from the checkpoint do not have the same size
as the weights of the model (if for instance, you are instantiating a model with 10 labels from a as the weights of the model (if for instance, you are instantiating a model with 10 labels from a
checkpoint with 3 labels). checkpoint with 3 labels).
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment