tusen-ai / Anchor3DLane

Official PyTorch implementation for paper`Anchor3DLane: Learning to Regress 3D Anchors for Monocular 3D Lane Detection' accepted by CVPR 2023

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

`anchor_assign = False` in multi-frame with iter

FiveLu opened this issue · comments

https://github.com/tusen-ai/Anchor3DLane/blob/bf64bd152e4550c43d9e61b19e4bc18b83661a32/configs/openlane/anchor3dlane_mf_iter.py#LL118C23-L118C28

Hi, i am so confused that why the Output-AUX branch uses anchor assign while the Ouput branch uses proposal assign ?

with torch.no_grad():
    if self.anchor_assign:
        positives_mask, negatives_mask, target_positives_indices = self.assigner.match_proposals_with_targets(
            anchors, target)
    else:
        positives_mask, negatives_mask, target_positives_indices = self.assigner.match_proposals_with_targets(
            proposals[:, :5+self.anchor_len*3], target)

Thanks !

It is merely a technical trick to assign labels according to anchors or proposals. Since the output predictions from the initial iteration do not fit well with the 3d lanes, we assign their labels according to the associated anchors for training stability. For the iterative predictions, they are generated based on predictions from the previous iteration and already fit well with the 3d lanes, thus we assign their labels directly according to the predicted proposals.