Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
chenpangpang
transformers
Commits
83d2d55c
Unverified
Commit
83d2d55c
authored
Feb 26, 2021
by
Julien Chaumond
Committed by
GitHub
Feb 26, 2021
Browse files
[ci, flax] non-existing models are unlikely to pass tests (#10409)
😂
parent
17b6e0d4
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
tests/test_flax_auto.py
tests/test_flax_auto.py
+2
-2
No files found.
tests/test_flax_auto.py
View file @
83d2d55c
...
@@ -41,7 +41,7 @@ class FlaxAutoModelTest(unittest.TestCase):
...
@@ -41,7 +41,7 @@ class FlaxAutoModelTest(unittest.TestCase):
@
slow
@
slow
def
test_roberta_from_pretrained
(
self
):
def
test_roberta_from_pretrained
(
self
):
for
model_name
in
[
"roberta-base
-cased
"
,
"roberta-large
-uncased
"
]:
for
model_name
in
[
"roberta-base"
,
"roberta-large"
]:
with
self
.
subTest
(
model_name
):
with
self
.
subTest
(
model_name
):
config
=
AutoConfig
.
from_pretrained
(
model_name
)
config
=
AutoConfig
.
from_pretrained
(
model_name
)
self
.
assertIsNotNone
(
config
)
self
.
assertIsNotNone
(
config
)
...
@@ -66,7 +66,7 @@ class FlaxAutoModelTest(unittest.TestCase):
...
@@ -66,7 +66,7 @@ class FlaxAutoModelTest(unittest.TestCase):
@
slow
@
slow
def
test_roberta_jax_jit
(
self
):
def
test_roberta_jax_jit
(
self
):
for
model_name
in
[
"roberta-base
-cased
"
,
"roberta-large
-uncased
"
]:
for
model_name
in
[
"roberta-base"
,
"roberta-large"
]:
tokenizer
=
AutoTokenizer
.
from_pretrained
(
model_name
)
tokenizer
=
AutoTokenizer
.
from_pretrained
(
model_name
)
model
=
FlaxRobertaModel
.
from_pretrained
(
model_name
)
model
=
FlaxRobertaModel
.
from_pretrained
(
model_name
)
tokens
=
tokenizer
(
"Do you support jax jitted function?"
,
return_tensors
=
TensorType
.
JAX
)
tokens
=
tokenizer
(
"Do you support jax jitted function?"
,
return_tensors
=
TensorType
.
JAX
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment