-
Notifications
You must be signed in to change notification settings - Fork 5
/
genotypes.py
7 lines (5 loc) · 1.79 KB
/
genotypes.py
1
2
3
4
5
6
7
from collections import namedtuple
Genotype = namedtuple('Genotype', 'normal normal_concat reduce reduce_concat')
FeafusionGenotype = namedtuple('FeafusionGenotype', ['normal','inside'])
fusion_genotype_resnet50= FeafusionGenotype(normal=[('SpatialAttention', 3, 0), ('dil_conv_3x3_dil4', 0, 0), ('dil_conv_3x3_dil4', 1, 0), ('dil_conv_3x3_dil4', 2, 0), ('dil_conv_3x3', 0, 1), ('sep_conv_3x3', 1, 1), ('sep_conv_3x3', 2, 1), ('SpatialAttention', 3, 1), ('ChannelAttention', 1, 2), ('dil_conv_3x3', 2, 2), ('sep_conv_3x3_rp2', 0, 2), ('SpatialAttention', 3, 2)], inside=[('SpatialAttention', 0), ('ChannelAttention', 1), ('sep_conv_3x3', 2), ('dil_conv_3x3_rp2', 3), ('sep_conv_3x3', 4), ('sep_conv_3x3_rp2', 0), ('SpatialAttention', 1), ('ChannelAttention', 2), ('dil_conv_3x3', 3), ('sep_conv_3x3_rp2', 4), ('dil_conv_3x3', 5), ('skip_connect', 6), ('dil_conv_3x3', 0), ('dil_conv_3x3_dil4', 1), ('dil_conv_3x3', 2), ('ChannelAttention', 3), ('skip_connect', 4), ('dil_conv_3x3_rp2', 5), ('ChannelAttention', 6)])
fusion_genotype_vgg16 = FeafusionGenotype(normal=[('dil_conv_3x3', 0, 0), ('dil_conv_3x3', 2, 0), ('none', 3, 0), ('none', 1, 0), ('dil_conv_3x3_dil4', 0, 1), ('dil_conv_3x3', 1, 1), ('SpatialAttention', 2, 1), ('dil_conv_3x3_rp2', 3, 1), ('dil_conv_3x3', 0, 2), ('dil_conv_3x3', 3, 2), ('dil_conv_3x3', 2, 2), ('SpatialAttention', 1, 2)], inside=[('dil_conv_3x3_rp2', 0), ('dil_conv_3x3_rp2', 1), ('ChannelAttention', 2), ('sep_conv_3x3_rp2', 3), ('SpatialAttention', 4), ('dil_conv_3x3_rp2', 0), ('sep_conv_3x3_rp2', 1), ('dil_conv_3x3', 2), ('dil_conv_3x3_rp2', 3), ('dil_conv_3x3_rp2', 4), ('dil_conv_3x3_rp2', 5), ('SpatialAttention', 6), ('dil_conv_3x3_rp2', 0), ('sep_conv_3x3_rp2', 1), ('SpatialAttention', 2), ('dil_conv_3x3', 3), ('dil_conv_3x3_rp2', 4), ('dil_conv_3x3_rp2', 5), ('SpatialAttention', 6)])