Giter Site home page Giter Site logo

iconcook's Introduction

Iconcook 图标识别

用 Pipcook 训练的图标识别工具

使用

# 安装依赖
$ npm install

# 启动服务
$ npm start

# 生成训练样本
http://localhost:3333

# 预览训练效果
http://localhost:3333/#/predict

流程

1、将图标名称列表存如 src/common/labels.js 中的 labels 数组

2、将图标名称和其 Unicode 编码以 key/value 的形式存入 src/common/labels.js 的 labelMap 对象

3、src/pages/create/index.jsx 中调整组件库名和样式,进入 http://localhost:3333 确认图标渲染正常

4、点击页面最下方的 "下载数据"(需要一段时间,console 有进度),将文件存入 iconData/icon.json

5、命令行运行 node createImg.js,会在 iconData/imgs 中生成图片训练集

6、将 iconData/imgs 下的三个文件夹打包为一个 zip 文件,得到训练集数据

7、调整 cook/icons.json 中的路径,命令行运行 pipcook run cook/icons.json 开始训练

8、完成训练后,将 cook/output/model 中的两个文件拷贝到 public 中

9、取出 cook/output/metadata.json 中 output/dataset 字段中的 labelArray 数组,放到 /src/pages/predict/index.jsx 的 resultLabels 字段

现在可以在 http://localhost:3333/#/predict 页面测试图标识别了

iconcook's People

Contributors

maplor avatar

Watchers

 avatar

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.