Git Product home page Git Product logo

Comments (24)

deping-1 avatar deping-1 commented on July 20, 2024

感谢您的分享,我直接使用train\dataset-line\0中的样例图片,直接训练时,观察到get_random_data处理后,lines中出现负坐标,请问这怎么修改?
https://github.com/chineseocr/table-detect/blob/master/image.py#L238

from table-detect.

yangyuqing15715165798 avatar yangyuqing15715165798 commented on July 20, 2024

你运行train.py,没有报错吗,下面的错误

OSError: Unable to open file (unable to open file: name = 'models/table-line.h5', errno = 2, error message = 'No such file or directory', flags = 0, o_flags = 0)

from table-detect.

solofive avatar solofive commented on July 20, 2024

@yangyuqing15715165798 ,你可以先确定下,你的目录结构对不对

from table-detect.

yangyuqing15715165798 avatar yangyuqing15715165798 commented on July 20, 2024

@yangyuqing15715165798 ,你可以先确定下,你的目录结构对不对

我改好了

from table-detect.

yangyuqing15715165798 avatar yangyuqing15715165798 commented on July 20, 2024

@yangyuqing15715165798 ,你可以先确定下,你的目录结构对不对

我改好了

你知道怎么用GPU训练吗

from table-detect.

solofive avatar solofive commented on July 20, 2024

@yangyuqing15715165798 安装tensorflow-gpu,就是gpu版本,作者的代码本身就是gpu版本的,只是没用gpu代码会自动使用cpu

from table-detect.

yangyuqing15715165798 avatar yangyuqing15715165798 commented on July 20, 2024

@yangyuqing15715165798 安装tensorflow-gpu,就是gpu版本,作者的代码本身就是gpu版本的,只是没用gpu代码会自动使用cpu

对,我安装tensorflow-gpu,就是默认还是cpu跑得,怎么才能使用gpu跑呢,代码里我没看到设置GPU的选项

from table-detect.

yangyuqing15715165798 avatar yangyuqing15715165798 commented on July 20, 2024

@yangyuqing15715165798 安装tensorflow-gpu,就是gpu版本,作者的代码本身就是gpu版本的,只是没用gpu代码会自动使用cpu

对,我安装tensorflow-gpu,就是默认还是cpu跑得,怎么才能使用gpu跑呢,代码里我没看到设置GPU的选项
或者是我gpu环境没配好

from table-detect.

solofive avatar solofive commented on July 20, 2024

@yangyuqing15715165798 嗷,想起来了,首先保证GPU内存至少大于4G,在train.py中的main 中添加指定使用GPU的代码(这个就是tensorflow使用GPU的,很好搜到)

from table-detect.

yangyuqing15715165798 avatar yangyuqing15715165798 commented on July 20, 2024

@yangyuqing15715165798 嗷,想起来了,首先保证GPU内存至少大于4G,在train.py中的main 中添加指定使用GPU的代码(这个就是tensorflow使用GPU的,很好搜到)

行,我试试

from table-detect.

deping-1 avatar deping-1 commented on July 20, 2024

@solofive @yangyuqing15715165798 你们在使用train/train.py训练时,有没有出现负坐标?
在image模块get_random_data处理后,lines中出现负坐标https://github.com/chineseocr/table-detect/blob/master/image.py#L238

from table-detect.

yangyuqing15715165798 avatar yangyuqing15715165798 commented on July 20, 2024

@solofive @yangyuqing15715165798 你们在使用train/train.py训练时,有没有出现负坐标?
在image模块get_random_data处理后,lines中出现负坐标https://github.com/chineseocr/table-detect/blob/master/image.py#L238

出现负坐标的话,那你训练的结果怎么样,训练集有多少

from table-detect.

deping-1 avatar deping-1 commented on July 20, 2024

@yangyuqing15715165798 我是直接的train\dataset-line\0目录里面的那5张图片,进行调试,发现的出现了负数坐标。我还没有开始训练

from table-detect.

solofive avatar solofive commented on July 20, 2024

@deping-1 根据代码所在位置,反推一下,lines是根据p1 = p1[0] * nw / iw + dx, p1[1] * nh / ih + dy,反推lines和nw ,iw ,dx,nh ,ih ,dy有关,iw,ih是原图片的size,就重点看一下nw ,dx,nh ,dy

from table-detect.

yangyuqing15715165798 avatar yangyuqing15715165798 commented on July 20, 2024

@yangyuqing15715165798 我是直接的train\dataset-line\0目录里面的那5张图片,进行调试,发现的出现了负数坐标。我还没有开始训练

这个我还没开始仔细研究,你看上面别人的想法

from table-detect.

deping-1 avatar deping-1 commented on July 20, 2024

@solofive 训练的结果怎么样,训练集有多少张图

from table-detect.

solofive avatar solofive commented on July 20, 2024

@deping-1 训练结果会出现像第一个issue说的,识别率会出现在0.4~0.5波动,我的需求原模型已经能给出很好的识别效果。我刚开始测试只用了20多张,训练后识别准确率会有提升。注意代码中的一些参数,可以适当调一调,效果会更好

from table-detect.

yangyuqing15715165798 avatar yangyuqing15715165798 commented on July 20, 2024

@deping-1 训练结果会出现像第一个issue说的,识别率会出现在0.4~0.5波动,我的需求原模型已经能给出很好的识别效果。我刚开始测试只用了20多张,训练后识别准确率会有提升。注意代码中的一些参数,可以适当调一调,效果会更好

你目前能达到多少准确度了?学习率需要调大一点吗

from table-detect.

solofive avatar solofive commented on July 20, 2024

@yangyuqing15715165798 你现在是遇到什么问题了吗,我没有调整学习率,准确度我有点忘了,但是目前业务使用下检测准确度相对还不错,目前遇到的都可以准确识别

from table-detect.

yangyuqing15715165798 avatar yangyuqing15715165798 commented on July 20, 2024

@yangyuqing15715165798 你现在是遇到什么问题了吗,我没有调整学习率,准确度我有点忘了,但是目前业务使用下检测准确度相对还不错,目前遇到的都可以准确识别

就是我的训练集准确率没有随着训练次数稳定提高,准确率在0.5左右徘徊不前

from table-detect.

solofive avatar solofive commented on July 20, 2024

@yangyuqing15715165798 这个确实是,训练次数过高准确率不会上升,准确率反而下降,原因暂时我没找到,但是在识别的时候,里面的方法中一些细小的参数可以调一调,准确率会上升一些

from table-detect.

yangyuqing15715165798 avatar yangyuqing15715165798 commented on July 20, 2024

@yangyuqing15715165798 这个确实是,训练次数过高准确率不会上升,准确率反而下降,原因暂时我没找到,但是在识别的时候,里面的方法中一些细小的参数可以调一调,准确率会上升一些

在训练时,是不是只需要json文件,jpg文件不需要吗?还有标注数据时,需要注意哪些信息

from table-detect.

solofive avatar solofive commented on July 20, 2024

@yangyuqing15715165798 源码只会加载json文件,标注过程中正常操作即可,确保你的横线和竖线有焦点;还有一个玄学就是,我用python3.6训练出的模型效果比3.7的好,不知道是什么原理,如果你的模型有点不尽如意,可以和我一样试试3.6

from table-detect.

deping-1 avatar deping-1 commented on July 20, 2024

@solofive 大佬,请问一下,你使用table-detect/train.py训练模型,是自己标注么,方便加个qq 349449878请教一下

from table-detect.

Related Issues (20)

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.