Skip to content

Where is the upper-left corner? #1

Description

@xiaoshuguo750

Hi!
Where is the upper-left corner?
34977556-f736ce08-fad5-11e7-9d2c-3d084671dfea
Does four vertex of pos Rectangular have a law,?such as clockwise, counterclockwise, I think these will affect the results of the function!
function:
def bboxes_to_grasps(bboxes):
box = tf.unstack(bboxes, axis=1)
x = (box[0] + (box[4] - box[0])/2) * 0.35
y = (box[1] + (box[5] - box[1])/2) * 0.47
tan = (box[3] -box[1]) / (box[2] -box[0]) *0.47/0.35
h = tf.sqrt(tf.pow((box[2] -box[0])*0.35, 2) + tf.pow((box[3] -box[1])*0.47, 2))
w = tf.sqrt(tf.pow((box[6] -box[0])*0.35, 2) + tf.pow((box[7] -box[1])*0.47, 2))
return x, y, tan, h, w

When the grab rectangle is tilted to the left or to the right, how does the upper left corner of the rectangle behave according to the above calculation formula?
抓取矩形朝左倾斜或朝右倾斜时,如果按照上述计算公式,矩形的左上角是怎么规定的呢?

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