fix(BEE): recover unmatched tokens in table last row when model under-predicts row count#3728
Open
AnkitAhlawat7742 wants to merge 2 commits into
Open
fix(BEE): recover unmatched tokens in table last row when model under-predicts row count#3728AnkitAhlawat7742 wants to merge 2 commits into
AnkitAhlawat7742 wants to merge 2 commits into
Conversation
…-predicts row count
Contributor
|
✅ DCO Check Passed Thanks @AnkitAhlawat7742, all your commits are properly signed off. 🎉 |
Contributor
Merge Protections🟢 Merge protection satisfied — ready to merge. Show 1 satisfied protection🟢 Enforce conventional commitMake sure that we follow https://www.conventionalcommits.org/en/v1.0.0/
|
I, Ankit.Ahlawat@ibm.com <Ankit.Ahlawat@ibm.com>, hereby add my Signed-off-by to this commit: 8d471bc Signed-off-by: Ankit.Ahlawat@ibm.com <Ankit.Ahlawat@ibm.com>
Member
|
@AnkitAhlawat7742 Thanks for the proposal. Before we resort to recovery-style post-processing, could you please check instead if enlarging the table detection a bit towards the bottom would cover this as well? Then we can see if that has undesired side effects on previously working tables and decide. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fix #3402
issue description
When the last row of a table sits at the very bottom edge of the table image crop , the TableFormer model fails to
predict it as a separate row. The tokens are present in the input token list and well within the page bounds, but the model simply doesn't output a row for them.
Resolves
This solution adds a post-processing recovery step in
TableStructureModel.predict_tablesthat detects word-level tokens not assigned to any predicted cell and appends them as an extra trailing row.