Skip to content

Commit

Permalink
support fc-ef fc-siam-conc fc-siam-diff
Browse files Browse the repository at this point in the history
  • Loading branch information
likyoo committed Nov 16, 2022
1 parent 67ac0d8 commit 1e34d00
Show file tree
Hide file tree
Showing 7 changed files with 543 additions and 183 deletions.
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,12 @@ Toolbox:

Change detection model:

- [x] [Changer (arXiv'2022)](configs/changer)
- [x] [FC-Siam-Diff (ICIP'2018)](configs/fcsn)
- [x] [FC-EF (ICIP'2018)](configs/fcsn)
- [x] [FC-Siam-diff (ICIP'2018)](configs/fcsn)
- [x] [FC-Siam-conc (ICIP'2018)](configs/fcsn)
- [x] [SNUNet (GRSL'2021)](configs/snunet)
- [x] [BiT (TGRS'2021)](configs/bit)
- [x] [Changer (arXiv'2022)](configs/changer)
- [ ] ...

The code of some models are borrowed directly from their official repositories.
Expand Down
23 changes: 23 additions & 0 deletions configs/_base_/models/fc_ef.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# model settings
norm_cfg = dict(type='SyncBN', requires_grad=True)
base_channels = 16
model = dict(
type='DIEncoderDecoder',
pretrained=None,
backbone=dict(
type='FC_EF',
in_channels=6,
base_channel=base_channels),
decode_head=dict(
type='FCNHead',
in_channels=base_channels,
channels=base_channels,
in_index=-1,
num_convs=0,
concat_input=False,
num_classes=2,
loss_decode=dict(
type='CrossEntropyLoss', use_sigmoid=False, loss_weight=1.0)),
# model training and testing settings
train_cfg=dict(),
test_cfg=dict(mode='whole'))
23 changes: 23 additions & 0 deletions configs/_base_/models/fc_siam_conc.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# model settings
norm_cfg = dict(type='SyncBN', requires_grad=True)
base_channels = 16
model = dict(
type='DIEncoderDecoder',
pretrained=None,
backbone=dict(
type='FC_Siam_conc',
in_channels=3,
base_channel=base_channels),
decode_head=dict(
type='FCNHead',
in_channels=base_channels,
channels=base_channels,
in_index=-1,
num_convs=0,
concat_input=False,
num_classes=2,
loss_decode=dict(
type='CrossEntropyLoss', use_sigmoid=False, loss_weight=1.0)),
# model training and testing settings
train_cfg=dict(),
test_cfg=dict(mode='whole'))
2 changes: 1 addition & 1 deletion configs/_base_/models/fc_siam_diff.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
type='DIEncoderDecoder',
pretrained=None,
backbone=dict(
type='SiamUnet_diff',
type='FC_Siam_diff',
in_channels=3,
base_channel=base_channels),
decode_head=dict(
Expand Down
5 changes: 3 additions & 2 deletions opencd/models/backbones/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
from .interaction_resnet import IA_ResNetV1c
from .interaction_resnest import IA_ResNeSt
from .siamunet_diff import SiamUnet_diff
from .fcsn import FC_EF, FC_Siam_diff, FC_Siam_conc
from .snunet import SNUNet_ECAM

__all__ = ['IA_ResNetV1c', 'IA_ResNeSt', 'SiamUnet_diff', 'SNUNet_ECAM']
__all__ = ['IA_ResNetV1c', 'IA_ResNeSt', 'FC_EF', 'FC_Siam_diff',
'FC_Siam_conc', 'SNUNet_ECAM']
Loading

0 comments on commit 1e34d00

Please sign in to comment.