Skip to content

"resize_points" function seems to be confusing width and height #2

Description

@chenjoya

Hi kuanfang, thank you for your excellent work. I found that the "resize_points" function seems to be confusing width and height:

opra/utils/dataset.py

Lines 17 to 22 in b4649e3

def _resize_points(points, src_shape, dst_shape):
"""Resize the points."""
xs = points[:, 0]
ys = points[:, 1]
new_xs = xs * dst_shape[0] / src_shape[0]
new_ys = ys * dst_shape[1] / src_shape[1]

Here shape[0], [1] should be width, height, respectively. But according here,

image_shape = (int(height), int(width))

shape[0], [1] is height, width, respectively.

Could I trouble you to clarify which one is correct, thank you!

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