Skip to content

Latest commit

 

History

History
26 lines (21 loc) · 706 Bytes

yolo2xml.md

File metadata and controls

26 lines (21 loc) · 706 Bytes

This function is used to convert yolo to xmls.

It is a reverse of 'xml2yolo'.

How to use.

import os
from convertmask.utils.yolo2xml.yolo2xml import *

BASE_DIR = os.path.abspath(os.path.dirname(
    os.getcwd())) + os.sep + 'static' + os.sep + 'yolo2xml' + os.sep

if __name__ == "__main__":
    txtpath = BASE_DIR + 'test.txt'
    imgpath = BASE_DIR + 'test.jpg'
    labelPath = BASE_DIR + 'voc.names'
    y2xConvert(txtPath=txtpath,imgPath=imgpath,labelPath=labelPath)