tfm.vision.anchor.unpack_targets

Unpacks an array of labels into multi-scales labels.

targets A tensor with shape [num_anchors, M] representing the packed targets with M values stored for each anchor.
anchor_boxes_dict An ordered dictionary with keys [min_level, min_level+1, ..., max_level]. The values are tensor with shape [height_l, width_l, num_anchors_per_location * 4]. The height_l and width_l represent the dimension of the feature pyramid at l-th level. For each anchor box, the tensor stores [y0, x0, y1, x1] for the four corners.

unpacked_targets An ordered dictionary with keys [min_level, min_level+1, ..., max_level]. The values are tensor with shape [height_l, width_l, num_anchors_per_location * M]. The height_l and width_l represent the dimension of the feature pyramid at l-th level. M is the number of values stored for each anchor.