├── .build ├── default.init.aardio ├── default.main.aardio └── default.Manifest.xml ├── dist ├── 8.jpg ├── 08.jpg └── res_2.jpg ├── res_2.jpg ├── santi.png ├── santi-result.png ├── .gitignore ├── default.aproj ├── main.aardio ├── lib └── config.aardio └── README.md /.build/default.init.aardio: -------------------------------------------------------------------------------- 1 | //发布前触发 2 | import ide; -------------------------------------------------------------------------------- /dist/8.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xuncv/chineseocrlite-aardio/HEAD/dist/8.jpg -------------------------------------------------------------------------------- /res_2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xuncv/chineseocrlite-aardio/HEAD/res_2.jpg -------------------------------------------------------------------------------- /santi.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xuncv/chineseocrlite-aardio/HEAD/santi.png -------------------------------------------------------------------------------- /dist/08.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xuncv/chineseocrlite-aardio/HEAD/dist/08.jpg -------------------------------------------------------------------------------- /dist/res_2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xuncv/chineseocrlite-aardio/HEAD/dist/res_2.jpg -------------------------------------------------------------------------------- /santi-result.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xuncv/chineseocrlite-aardio/HEAD/santi-result.png -------------------------------------------------------------------------------- /.build/default.main.aardio: -------------------------------------------------------------------------------- 1 | //此触发器在生成EXE以后执行 2 | import ide; 3 | import fsys; 4 | 5 | //获取生成的EXE文件路径 6 | var publishFile = ide.getPublishPath(); -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Prerequisites 2 | *.d 3 | 4 | # Compiled Object files 5 | *.slo 6 | *.lo 7 | *.o 8 | *.obj 9 | 10 | # Precompiled Headers 11 | *.gch 12 | *.pch 13 | 14 | # Compiled Dynamic libraries 15 | *.so 16 | *.dylib 17 | *.dll 18 | 19 | # Fortran module files 20 | *.mod 21 | *.smod 22 | 23 | # Compiled Static libraries 24 | *.lai 25 | *.la 26 | *.a 27 | *.lib 28 | 29 | # Executables 30 | *.exe 31 | *.out 32 | *.app 33 | 34 | #Models 35 | *.onnx 36 | *.txt -------------------------------------------------------------------------------- /default.aproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /main.aardio: -------------------------------------------------------------------------------- 1 | import console 2 | import ocrLite; 3 | 4 | var ocr = ocrLite(false) 5 | var ret = ocr.getResult("./santi.png") 6 | var textBlocks = ret.textBlocks 7 | for(i=1;#textBlocks){ 8 | console.log( textBlocks[i].text ) 9 | console.log( "字符识别置信度:",table.tostring(textBlocks[i].charScores,true) ) //字符识别置信度 10 | console.log( "文本框置信度:",textBlocks[i].boxScore ) //文本框置信度 11 | for(j=1;#textBlocks[i].point;1){ 12 | //文本框四角坐标 13 | //console.log(textBlocks[i].point[j].x,textBlocks[i].point[j].y) 14 | } 15 | } 16 | 17 | console.pause(true); -------------------------------------------------------------------------------- /lib/config.aardio: -------------------------------------------------------------------------------- 1 | //config 配置文件 2 | import fsys.config; 3 | config = fsys.config("/config/"); 4 | //config = fsys.config( io.appData("/软件作者/应用程序名/") ); 5 | 6 | //不需要序列化的配置名字前请添加下划线 7 | namespace config { 8 | __appName = "应用程序名"; 9 | __appVersion = "1.0.0.01"; 10 | __appDescription = "这是一个测试程序"; 11 | __website = "http://www.aardio.com/"; 12 | } 13 | 14 | /**intellisense(config) 15 | __appName = 应用程序名 16 | __appVersion = 应用程序内部版本号 17 | __appDescription = 程序说明 18 | __website = 官方网站 19 | ? = 配置文件名,\n读写配置并序列化为一个表对象,\n表的成员值可以是支持序列化的普通变量,支持table对象\n配置文件在首次使用时自动加载,退出程序时自动保存\n!fsys_table. 20 | end intellisense**/ -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # chineseocrlite-aardio 2 | #### chineseocrlite的aardio支持库 3 | 4 | 基于[chineseocr_lite](https://github.com/DayBreak-u/chineseocr_lite) 项目,针对aardio特性,制作的dll动态链接库。 5 | 6 | 所用技术: 7 | 8 | 1. crnn dbnet 9 | 2. onnx 10 | 3. opencv 11 | 12 | ##### 用法: 13 | 14 | 第一种:下载[ocrLite库](https://github.com/xuncv/chineseocrlite-aardio/releases/download/0.0.1/ocrLite.zip),放到aardio开发环境的lib目录下。 15 | 16 | 第二种:自动安装 17 | 18 | ``` 19 | 允许使用 _IMPORTURL 注册远程扩展库网址,例如: 20 | 21 | _IMPORTURL.ocrLite = "https://github.com/xuncv/chineseocrlite-aardio/releases/download/0.0.1/ocrLite.tar.lzma" 22 | import ocrLite; 23 | 24 | 也可以在aardio中单独运行下面的代码安装远程扩展库: 25 | 26 | import ide; 27 | ide.installLib("ocrLite","https://github.com/xuncv/chineseocrlite-aardio/releases/download/0.0.1/ocrLite.tar.lzma") 28 | 29 | ``` 30 | 31 | ![santi](./santi.png) 32 | 33 | 34 | 35 | ![santi-result](./santi-result.png) 36 | 37 | -------------------------------------------------------------------------------- /.build/default.Manifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 10 | onnx 11 | 12 | 13 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 52 | 53 | 54 | 55 | 56 | 57 | True/PM 58 | 59 | 60 | --------------------------------------------------------------------------------