Giter VIP home page Giter VIP logo

Comments (4)

bsmock avatar bsmock commented on May 19, 2024 1

I'm guessing if you made the change recently in the training it will need more epochs to adapt. However, you might have more success using or adapting another transform we include in the code but don't use for the paper and still haven't documented:

class TightAnnotationCrop(object):

This one can be used to crop directly to the table bounding box by doing TightAnnotationCrop([0], 0, 0, 0, 0), or with some random padding around the table bounding box by doing TightAnnotationCrop([0], 10, 10, 10, 10).

Keep in mind that this goes beyond what we do in the paper so we aren't officially supporting/documenting it at this time. However I hope you find it helpful!

from table-transformer.

bsmock avatar bsmock commented on May 19, 2024

Hi, yes this is expected behavior given the training data and data augmentation used in the paper.

However, we designed the data with robustness to padding around the table in mind. With small changes to the training code it should be easy to achieve whatever robustness you would like to padding around the true table border.

(As an aside, note that the reason we include padding in the training images is that if we had cropped all of the table images tightly to the table border then the opposite problem would be encountered: there would be no robustness to table images that have padding around the table.)

To achieve more robustness to different amounts of padding, the simplest change would be to increase the amount of cropping done during training here:

RandomCrop(1, 10, 10, 10, 10),

You can also modify the transforms or make your own transform to achieve your desired result. The true border for every table is included in the labels so you can train a model with any amount of padding around the table you would like.

Hope that helps!

from table-transformer.

RobbyJS avatar RobbyJS commented on May 19, 2024

Hello,
Thanks for those clarifications.

I have made some tests modifying the RandomCrop values, and the problem seems to persist. I have only managed to complete a couple epochs however. Should I expect an improvement when training for more epochs or I should modify more lines of code than just these:

To achieve more robustness to different amounts of padding, the simplest change would be to increase the amount of cropping done during training here:

RandomCrop(1, 10, 10, 10, 10),

I have modified both the maximum crop and also the minimum crop inside the RandomCrop transform.

Thanks again,

from table-transformer.

bsmock avatar bsmock commented on May 19, 2024

I believe I've addressed your question, so I will close this issue.

from table-transformer.

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.