Skip to content

Visualization of boxes #19

@o0t1ng0o

Description

@o0t1ng0o

Hi @volgachen,

I follow this code #10 (comment) to visualize the boxes.
Due to the amplifier=2, I resize the image to (224*2)X(224*2) and plot the boxes, centers and anchors in the image.
In this figure, the red points are anchors, the blue points are centers of boxes, and red rectangles are the boxes.

But I found that some boxes are outside the image.
I am wondering whether this is caused by the '16' in the following two lines in the code?

  1. boxes = (box_coder.boxes[0] * 224 + 16 ) * amplifier
  2. anchors = [(patch_embed.box_coder.anchor * 224 + 16)*amplifier for patch_embed in patch_embeds]

Or do I need to resize image to (256*2)X(256*2) during visualization since it preprocesses images by resizing to 256 and centercropping to 224?

image

Thank you very much.
Looking forward to further discussion with you.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions