parent
5f353e6c51
commit
7858ac2a68
25 changed files with 198 additions and 17 deletions
@ -1,6 +1,6 @@ |
||||
_base_: ./levircd.yaml |
||||
|
||||
save_dir: ./exp/bit/ |
||||
save_dir: ./exp/levircd/bit/ |
||||
|
||||
model: !Node |
||||
type: BIT |
||||
|
@ -0,0 +1,6 @@ |
||||
_base_: ./levircd.yaml |
||||
|
||||
save_dir: ./exp/levircd/fc_ef/ |
||||
|
||||
model: !Node |
||||
type: FCEarlyFusion |
@ -0,0 +1,6 @@ |
||||
_base_: ./levircd.yaml |
||||
|
||||
save_dir: ./exp/levircd/fc_siam_conc/ |
||||
|
||||
model: !Node |
||||
type: FCSiamConc |
@ -0,0 +1,6 @@ |
||||
_base_: ./levircd.yaml |
||||
|
||||
save_dir: ./exp/levircd/fc_siam_diff/ |
||||
|
||||
model: !Node |
||||
type: FCSiamDiff |
@ -0,0 +1,6 @@ |
||||
_base_: ./levircd.yaml |
||||
|
||||
save_dir: ./exp/levircd/stanet/ |
||||
|
||||
model: !Node |
||||
type: STANet |
@ -0,0 +1,6 @@ |
||||
_base_: ./svcd.yaml |
||||
|
||||
save_dir: ./exp/svcd/bit/ |
||||
|
||||
model: !Node |
||||
type: BIT |
@ -0,0 +1,12 @@ |
||||
_base_: ./svcd.yaml |
||||
|
||||
save_dir: ./exp/svcd/custom_model/ |
||||
|
||||
model: !Node |
||||
type: IterativeBIT |
||||
args: |
||||
num_iters: 3 |
||||
gamma: 0.5 |
||||
num_classes: 2 |
||||
bit_kwargs: |
||||
in_channels: 4 |
@ -0,0 +1,6 @@ |
||||
_base_: ./svcd.yaml |
||||
|
||||
save_dir: ./exp/svcd/fc_ef/ |
||||
|
||||
model: !Node |
||||
type: FCEarlyFusion |
@ -0,0 +1,6 @@ |
||||
_base_: ./svcd.yaml |
||||
|
||||
save_dir: ./exp/svcd/fc_siam_conc/ |
||||
|
||||
model: !Node |
||||
type: FCSiamConc |
@ -0,0 +1,6 @@ |
||||
_base_: ./svcd.yaml |
||||
|
||||
save_dir: ./exp/svcd/fc_siam_diff/ |
||||
|
||||
model: !Node |
||||
type: FCSiamDiff |
@ -0,0 +1,6 @@ |
||||
_base_: ./svcd.yaml |
||||
|
||||
save_dir: ./exp/svcd/stanet/ |
||||
|
||||
model: !Node |
||||
type: STANet |
@ -0,0 +1,74 @@ |
||||
# Basic configurations of SVCD dataset |
||||
|
||||
datasets: |
||||
train: !Node |
||||
type: CDDataset |
||||
args: |
||||
data_dir: ./data/svcd/ |
||||
file_list: ./data/svcd/train.txt |
||||
label_list: null |
||||
num_workers: 2 |
||||
shuffle: True |
||||
with_seg_labels: False |
||||
binarize_labels: True |
||||
eval: !Node |
||||
type: CDDataset |
||||
args: |
||||
data_dir: ./data/svcd/ |
||||
file_list: ./data/svcd/val.txt |
||||
label_list: null |
||||
num_workers: 0 |
||||
shuffle: False |
||||
with_seg_labels: False |
||||
binarize_labels: True |
||||
transforms: |
||||
train: |
||||
- !Node |
||||
type: DecodeImg |
||||
- !Node |
||||
type: RandomFlipOrRotate |
||||
args: |
||||
probs: [0.35, 0.35] |
||||
probsf: [0.5, 0.5, 0, 0, 0] |
||||
probsr: [0.33, 0.34, 0.33] |
||||
- !Node |
||||
type: Normalize |
||||
args: |
||||
mean: [0.5, 0.5, 0.5] |
||||
std: [0.5, 0.5, 0.5] |
||||
- !Node |
||||
type: ArrangeChangeDetector |
||||
args: ['train'] |
||||
eval: |
||||
- !Node |
||||
type: DecodeImg |
||||
- !Node |
||||
type: Normalize |
||||
args: |
||||
mean: [0.5, 0.5, 0.5] |
||||
std: [0.5, 0.5, 0.5] |
||||
- !Node |
||||
type: ArrangeChangeDetector |
||||
args: ['eval'] |
||||
download_on: False |
||||
|
||||
num_epochs: 200 |
||||
train_batch_size: 8 |
||||
optimizer: !Node |
||||
type: Adam |
||||
args: |
||||
learning_rate: !Node |
||||
type: StepDecay |
||||
module: paddle.optimizer.lr |
||||
args: |
||||
learning_rate: 0.0004 |
||||
step_size: 87500 |
||||
gamma: 0.1 |
||||
save_interval_epochs: 20 |
||||
log_interval_steps: 50 |
||||
save_dir: ./exp/ |
||||
learning_rate: 0.0004 |
||||
early_stop: False |
||||
early_stop_patience: 5 |
||||
use_vdl: True |
||||
resume_checkpoint: '' |
@ -0,0 +1,18 @@ |
||||
#!/bin/bash |
||||
|
||||
set -e |
||||
|
||||
for dataset in levircd svcd; do |
||||
config_dir="configs/${dataset}" |
||||
log_dir="exp/logs/${dataset}" |
||||
|
||||
mkdir -p "${log_dir}" |
||||
|
||||
for config_file in $(ls ${config_dir}); do |
||||
printf '=%.0s' {1..100} && echo |
||||
echo -e "\033[33m ${config_file} \033[0m" |
||||
printf '=%.0s' {1..100} && echo |
||||
python run_task.py train cd --config "${config_dir}/${config_file}" 2>&1 | tee "${log_dir}/${config_file%.*}" |
||||
echo |
||||
done |
||||
done |
@ -0,0 +1,16 @@ |
||||
#!/bin/bash |
||||
|
||||
set -e |
||||
|
||||
CONFIG_DIR='configs/levircd/custom_model' |
||||
LOG_DIR='exp/logs/parameter_analysis' |
||||
|
||||
mkdir -p "${LOG_DIR}" |
||||
|
||||
for config_file in $(ls ${CONFIG_DIR}); do |
||||
printf '=%.0s' {1..100} && echo |
||||
echo -e "\033[33m ${config_file} \033[0m" |
||||
printf '=%.0s' {1..100} && echo |
||||
python run_task.py train cd --config "${CONFIG_DIR}/${config_file}" 2>&1 | tee "${LOG_DIR}/${config_file%.*}" |
||||
echo |
||||
done |
Loading…
Reference in new issue