Skip to content

target by object area #91

@PT0X0E

Description

@PT0X0E

Hi, thanks for the work. I see in the code that targets are built by object areas as

output = torch.zeros((3, 80), dtype=torch.long)
for obj in target:
    if obj['area'] < 32 * 32:
        output[0][self.cat2cat[obj['category_id']]] = 1
    elif obj['area'] < 96 * 96:
        output[1][self.cat2cat[obj['category_id']]] = 1
    else:
        output[2][self.cat2cat[obj['category_id']]] = 1
target = output

and

for i, (inputData, target) in enumerate(train_loader):
    inputData = inputData.cuda()
    target = target.cuda()  # (batch,3,num_classes)
    target = target.max(dim=1)[0]

Why the targets are processed like this please?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions