【发布时间】:2019-11-20 22:18:51
【问题描述】:
我正在使用 Microsoft 的 CustomVision.ai 构建自定义视觉应用程序。
我正在使用this tutorial。
在物体检测项目中标记图像时,需要使用归一化坐标指定每个标记物体的区域。
我有一个 XML 文件,其中包含有关图像的注释,例如命名为sample_1.jpg:
<annotation>
<filename>sample_1.jpg</filename>
<size>
<width>410</width>
<height>400</height>
<depth>3</depth>
</size>
<object>
<bndbox>
<xmin>159</xmin>
<ymin>15</ymin>
<xmax>396</xmax>
<ymax>302</ymax>
</bndbox>
</object>
</annotation>
我必须根据提供的教程将边界框坐标从 xmin,xmax,ymin,ymax 转换为 x,y,w,h 坐标。
谁能给我一个转换函数?
【问题讨论】:
-
在这种情况下 x 和 y 是什么意思?
标签: python object-detection microsoft-custom-vision