from models.line_detect.heads.head_losses import features_align def ins_forward(model, features, image_shapes, proposals): # print(f'circle_proposals:{len(proposals)}') cs_features = features feature_logits = model.ins_decoder(cs_features) print(f'feature_logits from mask_decoder:{feature_logits.shape}') roi_features = features_align(feature_logits, proposals, image_shapes) if roi_features is not None: print(f'roi_features from align:{roi_features.shape}') return roi_features