Skip to content

There seems to be a bug in the Mosaic data augmentation? #1020

@haoyuefan

Description

@haoyuefan

I visualized the Mosaic data augmentation and found that some of the labels wrong shifted after the data augmentation. After debugging, I find there seems to be a problem with this line of the load_mosaic function:
x1b, y1b, x2b, y2b = w - (x2a - x1a), 0, max(xc, w), min(y2a - y1a, h)
the line 664 of dataset.py, I want to ask if this line should be changed:
x1b, y1b, x2b, y2b = w - (x2a - x1a), 0, w, min(y2a - y1a, h)
because in the bottom left patch of mosaic image, the xmax point of source image shouldn't be changed.
Hope you can reply me soon, thank you.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions