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
acaa2e62
"git@developer.sourcefind.cn:wangsen/paddle_dbnet.git" did not exist on "388d8dae331bca4fe89a15c843af7f7ea3f38079"
Unverified
Commit
acaa2e62
authored
Jun 05, 2020
by
Sylvain Gugger
Committed by
GitHub
Jun 05, 2020
Browse files
Clean-up code (#4790)
parent
fa661ce7
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
src/transformers/configuration_xlnet.py
src/transformers/configuration_xlnet.py
+3
-3
No files found.
src/transformers/configuration_xlnet.py
View file @
acaa2e62
...
@@ -164,9 +164,9 @@ class XLNetConfig(PretrainedConfig):
...
@@ -164,9 +164,9 @@ class XLNetConfig(PretrainedConfig):
self
.
n_head
=
n_head
self
.
n_head
=
n_head
assert
d_model
%
n_head
==
0
assert
d_model
%
n_head
==
0
if
"d_head"
in
kwargs
:
if
"d_head"
in
kwargs
:
assert
kwargs
[
"d_head"
]
==
d_model
//
n_head
,
(
assert
(
f
"`d_head` (
{
kwargs
[
'
d_head
'
]
}
) should be equal to `d_model // n_head` (
{
d_model
//
n_head
}
)"
kwargs
[
"
d_head
"
]
==
d_model
//
n_head
)
)
,
f
"`d_head` (
{
kwargs
[
'd_head'
]
}
) should be equal to `d_model // n_head` (
{
d_model
//
n_head
}
)"
self
.
d_head
=
d_model
//
n_head
self
.
d_head
=
d_model
//
n_head
self
.
ff_activation
=
ff_activation
self
.
ff_activation
=
ff_activation
self
.
d_inner
=
d_inner
self
.
d_inner
=
d_inner
...
...
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