SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2105.01848 · 2021

PingAn-VCGroup's Solution for ICDAR 2021 Competition on Scientific Literature Parsing Task B: Table Recognition to HTML

arXiv · PDF · Open in the Atlas

Code that ran

10 of 11 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (0 of them constructed an object rather than computing a result; 0 honoured the contract we drafted, 0 violated it and 10 have no contract verdict; 0 failures of our instrument; 1 no recorded run), measured 2026-11-22; repository links from the Papers with Code archive attributed under CC BY-SA, no affiliation; bodies inline only under a permissive licence as GitHub detects it. Not a reproduction of the paper's results.

"Ran" means the function executed on a synthesized input and returned a value. It is not a reproduction of the paper's results. This record, dated, as JSON: /api/ran/2105.01848.json · badge: /api/ran/2105.01848.svg

Each repository's role is a label: a classifier's output recorded on the link, or, where no role is recorded, what the Papers with Code archive marked. The line under it names its basis. Neither says who wrote the code.

RepositoryRoleRan
JiaquanYe/TableMASTER-mmocr community (classifier label)
classifier basis not recorded on the link
10 ran · 1 no recorded run
FunctionStatusWhere it lives
cal_true_positive_char Ran
ran on a synthesized input
JiaquanYe/TableMASTER-mmocr/mmocr/core/evaluation/ocr_metric.py
code served (permissive licence) · get_code("22f4f2f9b4dca7a7")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned int, ndim 0, dtype family int, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

from difflib import SequenceMatcher

# Setup arguments for cal_true_positive_char function
# The function takes two string parameters: pred (prediction) and gt (ground truth)
# It uses SequenceMatcher to find matching characters between them

ARGS = {
    "pred": "hello world",
    "gt": "hallo world"
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type int, ndim 0, dtype family int, shape () — shape () as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
compute_f1_all Ran
ran on a synthesized input
JiaquanYe/TableMASTER-mmocr/mmocr/core/evaluation/ner_metric.py
code served (permissive licence) · get_code("ef7d24d42496c8cb")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned dict. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import numpy as np
from collections import Counter

# The function expects:
# - pred_entities: a list where each element is a list of tuples (entity_type, entity_info)
# - gt_entities: a list where each element is a list of tuples (entity_type, entity_info)
# Both should have the same length and represent batch items

# Create sample data
# Each batch item contains a list of entities as tuples (type, span_or_id)
pred_entities = [
    [("PERSON", "John"), ("LOC", "NYC"), ("ORG", "Google")],
    [("PERSON", "Alice"), ("ORG", "Apple")]
]

gt_entities = [
    [("PERSON", "John"), ("LOC", "NYC"), ("PERSON", "Bob")],
    [("PERSON", "Alice"), ("ORG", "Apple"), ("LOC", "Boston")]
]

ARGS = {
    "pred_entities": pred_entities,
    "gt_entities": gt_entities
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type dict — a dict output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a dict output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
compute_f1_score Ran
ran on a synthesized input
JiaquanYe/TableMASTER-mmocr/mmocr/core/evaluation/kie_metric.py
code served (permissive licence) · get_code("aea4c67ed6d34617")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned ndarray, ndim 1, dtype family float, shape (3,) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch

torch.manual_seed(0)

# Small example: N=2 samples, C=4 classes
N = 2
C = 4

# preds: NxC probability map (N samples, C classes)
# Create predictions with shape (2, 4)
preds = torch.rand(N, C)

# gts: ground truth vector of size N with class indices
# Values must be in range [0, C)
gts = torch.LongTensor([0, 2])

# ignores: list of class indices to ignore
ignores = [3]

ARGS = {
    "preds": preds,
    "gts": gts,
    "ignores": ignores,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ndarray, ndim 1, dtype family float, shape (3,) — shape (3,) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
compute_hmean Ran
ran on a synthesized input
JiaquanYe/TableMASTER-mmocr/mmocr/core/evaluation/utils.py
code served (permissive licence) · get_code("5a69be89c2583352")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned tuple, ndim 1, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

# Setup code for compute_hmean function

ARGS = {
    "accum_hit_recall": 15,
    "accum_hit_prec": 12,
    "gt_num": 20,
    "pred_num": 18,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 1, dtype family float — a tuple output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
disable_text_recog_aug_test Ran
ran on a synthesized input
JiaquanYe/TableMASTER-mmocr/mmocr/apis/inference.py
code served (permissive licence) · get_code("e7fcd01e8fbd0259")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned MockConfig. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import numpy as np
from unittest.mock import MagicMock

torch.manual_seed(0)

class MockConfig:
    def __init__(self):
        self.data = MagicMock()
        
        # Create pipeline items
        transform1 = MagicMock()
        transform1.type = 'SomeOtherTransform'
        
        transform2 = MagicMock()
        transform2.type = 'MultiRotateAugOCR'
        transform2.transforms = [
            MagicMock(type='RotateAug1'),
            MagicMock(type='RotateAug2'),
            MagicMock(type='RotateAug3'),
        ]
        
        # Set up test pipeline
        self.data.test = MagicMock()
        self.data.test.pipeline = [transform1, transform2]

cfg = MockConfig()

ARGS = {
    'cfg': cfg
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type MockConfig — a MockConfig output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a MockConfig output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
eval_ner_f1 Ran
ran on a synthesized input
JiaquanYe/TableMASTER-mmocr/mmocr/core/evaluation/ner_metric.py
code served (permissive licence) · get_code("8922d6e16f03f0f5")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned dict. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

from collections import Counter

# Set seed for reproducibility
import torch
torch.manual_seed(0)

# Create sample ground truth infos
# Each gt_info should have 'label' dict with structure: {category: {sub_key: [[start, end], ...]}}
gt_infos = [
    {
        'text': 'John Smith works at Google in Mountain View',
        'label': {
            'PERSON': {'names': [[0, 4], [5, 10]]},
            'ORG': {'companies': [[20, 26]]},
            'LOC': {'locations': [[30, 43]]}
        }
    },
    {
        'text': 'Alice went to Paris',
        'label': {
            'PERSON': {'names': [[0, 5]]},
            'LOC': {'cities': [[14, 19]]}
        }
    }
]

# Create sample predictions
# Format: list of lists, where each inner list contains predicted entities [category, start, end]
results = [
    [
        ['PERSON', 0, 4],
        ['PERSON', 5, 10],
        ['ORG', 20, 26],
        ['LOC', 30, 43]
    ],
    [
        ['PERSON', 0, 5],
        ['LOC', 14, 19],
        ['ORG', 50, 60]  # This is a false positive
    ]
]

ARGS = {
    'results': results,
    'gt_infos': gt_infos
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type dict — a dict output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a dict output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
gt_label2entity Ran
ran on a synthesized input
JiaquanYe/TableMASTER-mmocr/mmocr/core/evaluation/ner_metric.py
code served (permissive licence) · get_code("59952ebc93508f68")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned list, ndim 3, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch

ARGS = {
    'gt_infos': [
        {
            'label': {
                'PERSON': {
                    'mentions': [[0, 5], [10, 15]]
                },
                'LOCATION': {
                    'mentions': [[20, 25]]
                }
            }
        },
        {
            'label': {
                'ORG': {
                    'mentions': [[2, 8], [30, 40], [50, 60]]
                }
            }
        }
    ]
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 3, dtype family float — a list output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
overlay_mask_img Ran
ran on a synthesized input
JiaquanYe/TableMASTER-mmocr/mmocr/core/visualize.py
code served (permissive licence) · get_code("51bc3232ec8e8744")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned ndarray, ndim 3, dtype family int, shape (32, 48, 3) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import cv2
import numpy as np

# Create a small test image (RGB format, uint8)
img = np.ones((32, 48, 3), dtype=np.uint8) * 200

# Create a simple binary mask
mask = np.zeros((32, 48), dtype=np.uint8)
mask[10:20, 15:35] = 255

ARGS = {
    "img": img,
    "mask": mask
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
cv2, numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ndarray, ndim 3, dtype family int, shape (32, 48, 3) — shape (32, 48, 3) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
points2boundary Ran
ran on a synthesized input
JiaquanYe/TableMASTER-mmocr/mmocr/core/mask.py
code served (permissive licence) · get_code("f9b4b952d392770f")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned list, ndim 1, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import numpy as np
import cv2

# Create valid test data for points2boundary function

# For 'quad' text representation type
# Points should be (n, 2) shape representing mask coordinates
quad_points = np.array([
    [10, 20],
    [50, 20],
    [50, 80],
    [10, 80]
], dtype=np.float32)

# For 'poly' text representation type
# Create a more complex polygon with multiple points
poly_points = np.array([
    [15, 25],
    [45, 20],
    [50, 35],
    [55, 70],
    [30, 85],
    [10, 75]
], dtype=np.float32)

# Test with quad representation
ARGS = {
    "points": quad_points,
    "text_repr_type": "quad",
    "text_score": 0.95,
    "min_width": 5
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
cv2, numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 1, dtype family float — a list output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
seg2boundary Ran
ran on a synthesized input
JiaquanYe/TableMASTER-mmocr/mmocr/core/mask.py
code served (permissive licence) · get_code("acefba8a62931b37")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned list, ndim 1, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import numpy as np

# Create a simple segmentation mask
seg = np.zeros((20, 20), dtype=np.uint8)
# Add some white pixels to form a shape
seg[5:15, 5:15] = 255

# Set text representation type
text_repr_type = 'quad'

# Set text score (optional)
text_score = 0.85

ARGS = {
    'seg': seg,
    'text_repr_type': text_repr_type,
    'text_score': text_score
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
cv2, numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 1, dtype family float — a list output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
compute_recall_precision Not yet run
unverified (harvested, no recorded run)
JiaquanYe/TableMASTER-mmocr/mmocr/core/evaluation/hmean_ic13.py
code served (permissive licence) · get_code("012f0abe5c1db28b")
How it ran

no invocation recorded.

Also present in other papers' code

Of 11 samples lifted from this paper's linked repositories, 11 carry a function identity and 0 do not. Of the 11 distinct functions with an identity, 3 are also present in other papers whose code we hold (0 with at least one paper dated earlier, 0 the same month, 3 later) and 8 are only here among the 52,977 papers whose code Syntology holds (as of 2026-09-26).

Only here means: among the 52,977 papers whose code Syntology holds (51,887 with lifted samples, 1,090 through their assemblies only), as of 2026-09-26, no other paper's lifted samples or current assembly bricks contain an identical function body after normalisation.

FunctionAlso present inEarliest-datedOthers named
overlay_mask_img 2 other papers
2 later
2208.00438 (2022-08)
Toward Understanding WordArt: Corner-Guided Transformer for Scene Text Recognition
2306.15142 (2023-06)
LRANet: Towards Accurate and Efficient Scene Text Detection with Low-Rank Approximation Network
points2boundary 2 other papers
2 later
2208.00438 (2022-08)
Toward Understanding WordArt: Corner-Guided Transformer for Scene Text Recognition
2306.15142 (2023-06)
LRANet: Towards Accurate and Efficient Scene Text Detection with Low-Rank Approximation Network
seg2boundary 2 other papers
2 later
2208.00438 (2022-08)
Toward Understanding WordArt: Corner-Guided Transformer for Scene Text Recognition
2306.15142 (2023-06)
LRANet: Towards Accurate and Efficient Scene Text Detection with Low-Rank Approximation Network

Presence, not direction: an identical function body in two papers' repositories does not say who wrote it, which came from which, or that either paper's method rests on it. Matching is exact after normalisation, so a renamed or edited function is not matched. Dates are when papers appeared, not when code was written. Only .py files the harvester lifted are covered; notebooks are not read. A new-style arXiv id YYMM.NNNN dates a paper to the month 20YY-MM; otherwise Paper.year dates it to the year; otherwise it is undated. Dates are when the paper appeared, not when the code was written. Read 2026-11-22.

Repositories linked to this paper

Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.

Abstract

This paper presents our solution for ICDAR 2021 competition on scientific literature parsing taskB: table recognition to HTML. In our method, we divide the table content recognition task into foursub-tasks: table structure recognition, text line detection, text line recognition, and box assignment.Our table structure recognition algorithm is customized based on MASTER [1], a robust image textrecognition algorithm. PSENet [2] is used to detect each text line in the table image. For text linerecognition, our model is also built on MASTER. Finally, in the box assignment phase, we associatedthe text boxes detected by PSENet with the structure item reconstructed by table structure prediction,and fill the recognized content of the text line into the corresponding item. Our proposed methodachieves a 96.84% TEDS score on 9,115 validation samples in the development phase, and a 96.32%TEDS score on 9,064 samples in the final evaluation phase.

For agents

The same record, over MCP at https://syntology.ai/mcp:

get_harvested_code_for_paper("2105.01848")
get_code_for_paper("2105.01848")
have("2105.01848")

The run record, dated, one paper per request, free:

curl https://syntology.ai/api/ran/2105.01848.json

A badge for a README (the split and the date, never a ratio):

[![Syntology run record](https://syntology.ai/api/ran/2105.01848.svg)](https://syntology.ai/paper/2105.01848)

Connect an agent — have() is free.