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
03491ed2
You need to sign in or sign up before continuing.
Unverified
Commit
03491ed2
authored
Mar 29, 2021
by
ZhangShilong
Committed by
GitHub
Mar 29, 2021
Browse files
[Enhancement]: add more detail of warning in basemodule (#899)
parent
75d907c9
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
mmcv/runner/base_module.py
mmcv/runner/base_module.py
+2
-2
No files found.
mmcv/runner/base_module.py
View file @
03491ed2
...
@@ -47,8 +47,8 @@ class BaseModule(nn.Module, metaclass=ABCMeta):
...
@@ -47,8 +47,8 @@ class BaseModule(nn.Module, metaclass=ABCMeta):
module
.
init_weight
()
module
.
init_weight
()
self
.
_is_init
=
True
self
.
_is_init
=
True
else
:
else
:
warnings
.
warn
(
'This module has bee initialized,
\
warnings
.
warn
(
f
'init_weight of
{
self
.
__class__
.
__name__
}
has '
please call initialize(module, init_cfg) to reinitialize it
'
)
f
'been called more than once.
'
)
def
__repr__
(
self
):
def
__repr__
(
self
):
s
=
super
().
__repr__
()
s
=
super
().
__repr__
()
...
...
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