-
Notifications
You must be signed in to change notification settings - Fork 0
/
pan_r18_tt.py
61 lines (61 loc) · 1.17 KB
/
pan_r18_tt.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
model = dict(
type='PAN',
backbone=dict(
type='resnet18',
pretrained=True
),
neck=dict(
type='FPEM_v1',
in_channels=(64, 128, 256, 512),
out_channels=128
),
detection_head=dict(
type='PA_Head',
in_channels=512,
hidden_dim=128,
num_classes=6,
loss_text=dict(
type='DiceLoss',
loss_weight=1.0
),
loss_kernel=dict(
type='DiceLoss',
loss_weight=0.5
),
loss_emb=dict(
type='EmbLoss_v1',
feature_dim=4,
loss_weight=0.25
)
)
)
data = dict(
batch_size=16,
train=dict(
type='PAN_TT',
split='train',
is_transform=True,
img_size=640,
short_size=640,
kernel_scale=0.7,
read_type='cv2'
),
test=dict(
type='PAN_TT',
split='test',
short_size=640,
read_type='cv2'
)
)
train_cfg = dict(
lr=1e-3,
schedule='polylr',
epoch=600,
optimizer='Adam'
)
test_cfg = dict(
min_score=0.87,
min_area=16,
bbox_type='poly',
result_path='outputs/submit_tt/'
)