GithubHelp home page GithubHelp logo

a2824256 / labelme-dataset-extension-script Goto Github PK

View Code? Open in Web Editor NEW
0.0 2.0 0.0 21 KB

对已使用labelme标注的数据集生成左右/上下镜面翻转后的图片与标注文件的python脚本,与labelme转labelimg脚本。

Home Page: https://blog.csdn.net/a2824256/article/details/106231949

License: MIT License

Python 100.00%
labelme python labelimg

labelme-dataset-extension-script's Introduction

Labelme-dataset-extension-script

对已使用labelme标注的数据集生成左右/上下镜面翻转后的图片与标注文件

开发环境

python 3.6.10

使用教程

https://blog.csdn.net/a2824256/article/details/106231949

labeme是什么?

一个用于标注图像语义分割或者说图像实例分割的标注软件

labelme标注文件格式

  • shapes - 标注的多边形数据
  • imagePath - 图片路径
  • imageData - 图片base64转义的图像数据
  • imageHeight - 图像的高度
  • imageWidth - 图像的宽度

特别说明

labelme读取的是json文件里的数据,图片数据是读imageData的base64数据而不是原图

使用说明

直接修改transform.py文件顶部这几个参数即可使用

# 数据集路径
path = ".\\data\\"
# 生成数据的保存路径
save_path = ".\\data\\"
# 当前数据集图片格式
file_format = ".jpg"
# 替换格式jpg -> json
replace_format = ".json"
# 左右翻转文件名附加字符
LR = "lr_"
# 上下翻转文件名附加字符
TB = "tb_"

# 最后执行
python transform.py

更新

2020/09/03 - 更新labelme(语义分割)转labelimg(目标检测)标注文件
- labelme数据增广方案整合paddlepaddle官方提供的随机亮度、对比度、颜色微调方法

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.