Skip to content

why in test.py we transform each frame of a video 3 times? #6

@JavanehBahrami

Description

@JavanehBahrami

Hi all, I can not understand why for each frame of a video we do redundant transformation (3 times)?

                    for i in range(3):
                        image = cv2.cvtColor(src, cv2.COLOR_BGR2RGB)
                        image = transform(image)
                        image = image.unsqueeze(0)
                        feature = network.forward(image)
                        feature = F.normalize(feature, dim=1)
                        score = F.softmax(loss.amsm_loss.s * loss.amsm_loss.fc(feature.squeeze()), dim=0)
                        score_lst.append(score)

the score_lst is always the same at the end of the loop. I don't know why? please could you explain it?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions