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
01cb2f25
"git@developer.sourcefind.cn:chenpangpang/transformers.git" did not exist on "f68796bd603ef60173e093f50a1ecbb74bc2ba6b"
Unverified
Commit
01cb2f25
authored
Jul 15, 2021
by
Lysandre Debut
Committed by
GitHub
Jul 15, 2021
Browse files
LXMERT integration test typo (#12736)
parent
199b4c52
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
tests/test_modeling_lxmert.py
tests/test_modeling_lxmert.py
+1
-1
No files found.
tests/test_modeling_lxmert.py
View file @
01cb2f25
...
@@ -738,7 +738,7 @@ class LxmertModelIntegrationTest(unittest.TestCase):
...
@@ -738,7 +738,7 @@ class LxmertModelIntegrationTest(unittest.TestCase):
model
=
LxmertModel
.
from_pretrained
(
LXMERT_PRETRAINED_MODEL_ARCHIVE_LIST
[
0
])
model
=
LxmertModel
.
from_pretrained
(
LXMERT_PRETRAINED_MODEL_ARCHIVE_LIST
[
0
])
input_ids
=
torch
.
tensor
([[
101
,
345
,
232
,
328
,
740
,
140
,
1695
,
69
,
6078
,
1588
,
102
]])
input_ids
=
torch
.
tensor
([[
101
,
345
,
232
,
328
,
740
,
140
,
1695
,
69
,
6078
,
1588
,
102
]])
num_visual_features
=
10
num_visual_features
=
10
_
,
visual_feats
=
np
.
random
.
seed
(
0
),
np
.
random
.
rand
(
1
,
num_visual_features
,
LxmertM
odel
.
config
.
visual_feat_dim
)
_
,
visual_feats
=
np
.
random
.
seed
(
0
),
np
.
random
.
rand
(
1
,
num_visual_features
,
m
odel
.
config
.
visual_feat_dim
)
_
,
visual_pos
=
np
.
random
.
seed
(
0
),
np
.
random
.
rand
(
1
,
num_visual_features
,
4
)
_
,
visual_pos
=
np
.
random
.
seed
(
0
),
np
.
random
.
rand
(
1
,
num_visual_features
,
4
)
visual_feats
=
torch
.
as_tensor
(
visual_feats
,
dtype
=
torch
.
float32
)
visual_feats
=
torch
.
as_tensor
(
visual_feats
,
dtype
=
torch
.
float32
)
visual_pos
=
torch
.
as_tensor
(
visual_pos
,
dtype
=
torch
.
float32
)
visual_pos
=
torch
.
as_tensor
(
visual_pos
,
dtype
=
torch
.
float32
)
...
...
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