def SEm_resnet34(backbone_pretrained=True, used_layers=('layer3', ), pool_size=None, unfreeze_layer3=False): # backbone backbone_net = backbones.resnet34(pretrained=backbone_pretrained) # neck neck_net = Corr(pool_size=pool_size) # multiple heads mask_head = mask.Mask_Predictor_fine() # net net = SEcmnet(feature_extractor=backbone_net, neck_module=neck_net, head_module=(None, mask_head), used_layers=used_layers, extractor_grad=True, unfreeze_layer3=unfreeze_layer3) return net
def SEc_resnet34(backbone_pretrained=True, used_layers=('layer3', ), pool_size=None, unfreeze_layer3=False): # backbone backbone_net = backbones.resnet34(pretrained=backbone_pretrained) # neck neck_net = Corr(pool_size=pool_size) # multiple heads corner_head = corner_coarse.Corner_Predictor(inplanes=pool_size * pool_size) # 64 # net net = SEcmnet(feature_extractor=backbone_net, neck_module=neck_net, head_module=(corner_head, None), used_layers=used_layers, extractor_grad=True, unfreeze_layer3=unfreeze_layer3) return net