Skip to content

Commit

Permalink
Support for TF >= 2.7 (#14345)
Browse files Browse the repository at this point in the history
  • Loading branch information
sgugger authored Nov 9, 2021
1 parent e81d8d7 commit 46d0cda
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -151,8 +151,8 @@
"sphinxext-opengraph==0.4.1",
"sphinx-intl",
"starlette",
"tensorflow-cpu>=2.3,<2.7",
"tensorflow>=2.3,<2.7",
"tensorflow-cpu>=2.3",
"tensorflow>=2.3",
"timeout-decorator",
"timm",
"tokenizers>=0.10.1,<0.11",
Expand Down
4 changes: 2 additions & 2 deletions src/transformers/dependency_versions_table.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,8 @@
"sphinxext-opengraph": "sphinxext-opengraph==0.4.1",
"sphinx-intl": "sphinx-intl",
"starlette": "starlette",
"tensorflow-cpu": "tensorflow-cpu>=2.3,<2.7",
"tensorflow": "tensorflow>=2.3,<2.7",
"tensorflow-cpu": "tensorflow-cpu>=2.3",
"tensorflow": "tensorflow>=2.3",
"timeout-decorator": "timeout-decorator",
"timm": "timm",
"tokenizers": "tokenizers>=0.10.1,<0.11",
Expand Down
2 changes: 1 addition & 1 deletion src/transformers/models/roformer/modeling_tf_roformer.py
Original file line number Diff line number Diff line change
Expand Up @@ -1060,7 +1060,7 @@ class TFRoFormerClassificationHead(tf.keras.layers.Layer):
"""Head for sentence-level classification tasks."""

def __init__(self, config: RoFormerConfig, *inputs, **kwargs):
super().__init__(config, *inputs, **kwargs)
super().__init__(*inputs, **kwargs)

self.dense = tf.keras.layers.Dense(
units=config.hidden_size, kernel_initializer=get_initializer(config.initializer_range), name="dense"
Expand Down

0 comments on commit 46d0cda

Please sign in to comment.