Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

YOLO_Transform转换过程中解决出现图片占用问题(windows系统下) #21

Open
z931761491 opened this issue Apr 11, 2023 · 1 comment

Comments

@z931761491
Copy link

最近在使用作者的YOLO_Transform.py转换DOTA数据格式时,如果是转换split后的图片的数据格式,因为split后有时会出现一个图片中gt为0的情况,这时需要删除该gt数目为0的图片和对应的label文件,此时出现了图片占用问题,需要修改一下代码。在dota2LongSideFormat这个方法中,将 img = Image.open(img_fullname)修改为
fp = open(img_fullname, 'rb') img = Image.open(fp) fp.close()
修改后运行正常,Linux下没试过,应该不会出现这种情况。

@ulyduts
Copy link

ulyduts commented Jul 18, 2023

牛啊,解决了

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants