[Flax] Fix erroneous kwargs being passed to generate config (#21765)

This commit is contained in:
Sanchit Gandhi 2023-02-24 09:59:18 +01:00 committed by GitHub
parent 14f33205a7
commit 75bd49ff88
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -653,7 +653,7 @@ class FlaxPreTrainedModel(PushToHubMixin, FlaxGenerationMixin):
**kwargs,
)
else:
model_kwargs = kwargs
model_kwargs = kwargs.copy()
if commit_hash is None:
commit_hash = getattr(config, "_commit_hash", None)