Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
chenpangpang
transformers
Commits
2de90bee
Unverified
Commit
2de90bee
authored
Jan 27, 2022
by
Matt
Committed by
GitHub
Jan 27, 2022
Browse files
Super-small fix stops us confusing Keras console logging by modifying its logs (#15373)
parent
fa6dce25
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
0 deletions
+1
-0
src/transformers/keras_callbacks.py
src/transformers/keras_callbacks.py
+1
-0
No files found.
src/transformers/keras_callbacks.py
View file @
2de90bee
...
@@ -324,6 +324,7 @@ class PushToHubCallback(Callback):
...
@@ -324,6 +324,7 @@ class PushToHubCallback(Callback):
)
)
def
on_epoch_end
(
self
,
epoch
,
logs
=
None
):
def
on_epoch_end
(
self
,
epoch
,
logs
=
None
):
logs
=
logs
.
copy
()
# Don't accidentally write things that Keras will read later
if
"epoch"
not
in
logs
:
if
"epoch"
not
in
logs
:
logs
[
"epoch"
]
=
epoch
logs
[
"epoch"
]
=
epoch
self
.
training_history
.
append
(
logs
)
self
.
training_history
.
append
(
logs
)
...
...
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