|
1 |
| -# Scripts for extracting tables |
| 1 | +# AxCell: Automatic Extraction of Results from Machine Learning Papers |
| 2 | +[](https://paperswithcode.com/sota/scientific-results-extraction-on-pwc?p=axcell-automatic-extraction-of-results-from) |
| 3 | +[](https://paperswithcode.com/sota/scientific-results-extraction-on-nlp-tdms-exp?p=axcell-automatic-extraction-of-results-from) |
2 | 4 |
|
3 |
| -Dependencies: |
4 |
| - * [jq](https://stedolan.github.io/jq/) (`sudo apt install jq`) |
5 |
| - * docker (run without `sudo`) |
6 |
| - * [conda](https://www.anaconda.com/distribution/) |
| 5 | +This repository is the official implementation of [AxCell: Automatic Extraction of Results from Machine Learning Papers](https://arxiv.org/abs/2004.14356). |
7 | 6 |
|
8 |
| -Directory structure: |
9 |
| -``` |
10 |
| -. |
11 |
| -└── data |
12 |
| - ├── annotations |
13 |
| - │ └── evaluation-tables.json.gz # current annotations |
14 |
| - └── arxiv |
15 |
| - ├── sources # gzip archives with e-prints |
16 |
| - ├── unpacked\_sources # automatically extracted latex sources |
17 |
| - ├── htmls # automatically generated htmls |
18 |
| - ├── htmls-clean # htmls fixed by chromium |
19 |
| - └── tables # extracted tables |
| 7 | + |
| 8 | + |
| 9 | +```bibtex |
| 10 | +@inproceedings{axcell, |
| 11 | + title={AxCell: Automatic Extraction of Results from Machine Learning Papers}, |
| 12 | + author={Marcin Kardas, Piotr Czapla, Pontus Stenetorp, |
| 13 | + Sebastian Ruder, Sebastian Riedel, Ross Taylor, Robert Stojnic}, |
| 14 | + year={2020}, |
| 15 | + booktitle={2004.14356} |
| 16 | +} |
20 | 17 | ```
|
21 | 18 |
|
| 19 | +## Requirements |
22 | 20 |
|
23 |
| -To preprocess data and extract tables and texts, run: |
24 |
| -``` |
25 |
| -make pull_images |
| 21 | +To create a [conda](https://www.anaconda.com/distribution/) environment named `axcell` and install requirements run: |
| 22 | + |
| 23 | +```setup |
26 | 24 | conda env create -f environment.yml
|
27 |
| -source activate xtables |
28 |
| -make -j 8 -i extract_all > stdout.log 2> stderr.log |
29 | 25 | ```
|
30 |
| -where `8` is number of jobs to run simultaneously. Optionally one can specify path to data directory, f.e., `make DATA_DIR=mydata ...`. |
31 | 26 |
|
32 |
| -## Test |
33 |
| -To test the whole extraction on a single file run |
34 |
| -``` |
35 |
| -make test |
36 |
| -``` |
| 27 | +Additionally, `axcell` requires `docker` (that can be run without `sudo`). Run `scripts/pull_docker_images.sh` to download necessary images. |
37 | 28 |
|
38 |
| -### Unit Tests |
| 29 | +## Datasets |
| 30 | +We publish the following datasets: |
| 31 | +* [ArxivPapers](https://github.com/paperswithcode/axcell/releases/download/v1.0/arxiv-papers.csv.xz) |
| 32 | +* [SegmentedTables & LinkedResults](https://github.com/paperswithcode/axcell/releases/download/v1.0/segmented-tables.json.xz) |
| 33 | +* [PWCLeaderboards](https://github.com/paperswithcode/axcell/releases/download/v1.0/pwc-leaderboards.json.xz) |
39 | 34 |
|
40 |
| -``` |
41 |
| -PYTHONPATH=. py.test |
| 35 | +See [datasets](notebooks/datasets.ipynb) notebook for an example of how to load the datasets provided below. The [extraction](notebooks/extraction.ipynb) notebook shows how to use `axcell` to extract text and tables from papers. |
| 36 | +## Training |
| 37 | + |
| 38 | + |
| 39 | + |
| 40 | +## Evaluation |
| 41 | + |
| 42 | +See the [evaluation](notebooks/evaluation.ipynb) notebook for the full example on how to evaluate AxCell on the PWCLeaderboards dataset. |
| 43 | + |
| 44 | +## Pre-trained Models |
| 45 | + |
| 46 | +You can download pretrained models here: |
| 47 | + |
| 48 | +- [axcell](https://github.com/paperswithcode/axcell/releases/download/v1.0/models.tar.xz) — an archive containing the taxonomy, abbreviations, table type classifier and table segmentation model. See the [results-extraction](notebooks/results-extraction.ipynb) notebook for an example of how to load and run the models |
| 49 | +- [language model](https://github.com/paperswithcode/axcell/releases/download/v1.0/lm.xz) — [ULMFiT](https://arxiv.org/abs/1801.06146) language model pretrained on the ArxivPapers dataset |
| 50 | + |
| 51 | +## Results |
| 52 | + |
| 53 | +AxCell achieves the following performance: |
| 54 | + |
| 55 | +### |
| 56 | + |
| 57 | + |
| 58 | +| Dataset | Macro F1 | Micro F1 | |
| 59 | +| ---------- |---------------- | -------------- | |
| 60 | +| [PWC Leaderboards](https://beta.paperswithcode.com/sota/scientific-results-extraction-on-pwc) | 21.1 | 28.7 | |
| 61 | +| [NLP-TDMS](https://beta.paperswithcode.com/sota/scientific-results-extraction-on-nlp-tdms-exp) | 19.7 | 25.8 | |
| 62 | + |
| 63 | + |
| 64 | + |
| 65 | +## License |
| 66 | + |
| 67 | +AxCell is released under the [Apache 2.0 license](LICENSE). |
| 68 | + |
| 69 | +### Citation |
| 70 | +The pipeline is described in the following paper: |
| 71 | +```bibtex |
| 72 | +@inproceedings{axcell, |
| 73 | + title={AxCell: Automatic Extraction of Results from Machine Learning Papers}, |
| 74 | + author={Marcin Kardas and Piotr Czapla and Pontus Stenetorp and Sebastian Ruder and Sebastian Riedel and Ross Taylor and Robert Stojnic}, |
| 75 | + year={2020}, |
| 76 | + booktitle={2004.14356} |
| 77 | +} |
42 | 78 | ```
|
0 commit comments