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
OpenDAS
MMCV
Commits
9071202f
Commit
9071202f
authored
Oct 27, 2021
by
ly015
Committed by
Wenwei Zhang
Nov 10, 2021
Browse files
fix PaviLoggerHook
parent
792473c9
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
1 deletion
+5
-1
mmcv/runner/hooks/logger/pavi.py
mmcv/runner/hooks/logger/pavi.py
+5
-1
No files found.
mmcv/runner/hooks/logger/pavi.py
View file @
9071202f
...
...
@@ -44,7 +44,7 @@ class PaviLoggerHook(LoggerHook):
if
not
self
.
init_kwargs
:
self
.
init_kwargs
=
dict
()
self
.
init_kwargs
[
'
task
'
]
=
self
.
run_name
self
.
init_kwargs
[
'
name
'
]
=
self
.
run_name
self
.
init_kwargs
[
'model'
]
=
runner
.
_model_name
if
runner
.
meta
is
not
None
:
if
'config_dict'
in
runner
.
meta
:
...
...
@@ -112,3 +112,7 @@ class PaviLoggerHook(LoggerHook):
image
=
data
[
self
.
img_key
][
0
:
1
].
to
(
device
)
with
torch
.
no_grad
():
self
.
writer
.
add_graph
(
_model
,
image
)
def
__del__
(
self
):
if
hasattr
(
self
,
'writer'
):
self
.
writer
.
close
()
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