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
72ca0f30
Unverified
Commit
72ca0f30
authored
Nov 22, 2022
by
ckirchhoff
Committed by
GitHub
Nov 22, 2022
Browse files
[Fix] Fix the bug when input mask is not '0-1-tensor' in masked_conv (#2423)
parent
6e3827d0
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
0 deletions
+2
-0
mmcv/ops/masked_conv.py
mmcv/ops/masked_conv.py
+2
-0
No files found.
mmcv/ops/masked_conv.py
View file @
72ca0f30
...
...
@@ -58,6 +58,8 @@ class MaskedConv2dFunction(Function):
if
mask
.
size
()[
1
:]
!=
output
.
size
()[
2
:]:
raise
ValueError
(
'The mask is inconsistent with the shape of output_conv.'
)
mask
=
mask
>
0
mask
=
mask
.
type
(
output
.
dtype
)
output
=
output
*
mask
return
output
...
...
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