diff --git a/configs/_base_/models/stdc.py b/configs/_base_/models/stdc.py index e313f0443..341a4ec58 100644 --- a/configs/_base_/models/stdc.py +++ b/configs/_base_/models/stdc.py @@ -68,7 +68,7 @@ model = dict( in_index=0, norm_cfg=norm_cfg, concat_input=False, - align_corners=False, + align_corners=True, loss_decode=[ dict( type='CrossEntropyLoss', diff --git a/mmseg/models/decode_heads/stdc_head.py b/mmseg/models/decode_heads/stdc_head.py index 716001639..1e678ace1 100644 --- a/mmseg/models/decode_heads/stdc_head.py +++ b/mmseg/models/decode_heads/stdc_head.py @@ -80,11 +80,6 @@ class STDCHead(FCNHead): boudary_targets_pyramid[ boudary_targets_pyramid <= self.boundary_threshold] = 0 - seg_logit = F.interpolate( - seg_logit, - boundary_targets.shape[2:], - mode='bilinear', - align_corners=True) loss = super(STDCHead, self).losses(seg_logit, boudary_targets_pyramid.long()) return loss