vis4d.op.box.matchers.base

Matchers.

Classes

MatchResult(assigned_gt_indices, ...)

Match result class.

Matcher(*args, **kwargs)

Base class for box / target matchers.

class MatchResult(assigned_gt_indices: Tensor, assigned_gt_iou: Tensor, assigned_labels: Tensor)[source]

Match result class. Stores expected result tensors.

assigned_gt_indices: torch.Tensor - Tensor of [0, M) where M = num gt assigned_gt_iou: torch.Tensor - Tensor with IoU to assigned GT assigned_labels: torch.Tensor - Tensor of {0, -1, 1} = {neg, ignore, pos}

Create new instance of MatchResult(assigned_gt_indices, assigned_gt_iou, assigned_labels)

assigned_gt_indices: Tensor

Alias for field number 0

assigned_gt_iou: Tensor

Alias for field number 1

assigned_labels: Tensor

Alias for field number 2

class Matcher(*args, **kwargs)[source]

Base class for box / target matchers.

Initialize internal Module state, shared by both nn.Module and ScriptModule.

__call__(boxes, targets)[source]

Type declaration for forward.

Return type:

MatchResult

abstract forward(boxes, targets)[source]

Match bounding boxes according to their struct.

Return type:

MatchResult