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
44e19ff6
Unverified
Commit
44e19ff6
authored
Jul 13, 2021
by
Ye Liu
Committed by
GitHub
Jul 13, 2021
Browse files
[Feature]: Register CrissCrossAttention into plugin layers (#1189)
parent
96c4b70c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
1 deletion
+2
-1
mmcv/ops/cc_attention.py
mmcv/ops/cc_attention.py
+2
-1
No files found.
mmcv/ops/cc_attention.py
View file @
44e19ff6
...
...
@@ -3,7 +3,7 @@ import torch.nn as nn
import
torch.nn.functional
as
F
from
torch.autograd.function
import
once_differentiable
from
mmcv.cnn
import
Scale
from
mmcv.cnn
import
PLUGIN_LAYERS
,
Scale
from
..utils
import
ext_loader
ext_module
=
ext_loader
.
load_ext
(
...
...
@@ -66,6 +66,7 @@ ca_weight = CAWeightFunction.apply
ca_map
=
CAMapFunction
.
apply
@
PLUGIN_LAYERS
.
register_module
()
class
CrissCrossAttention
(
nn
.
Module
):
"""Criss-Cross Attention Module."""
...
...
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