Register
Login
Resources
Docs Blog Datasets Glossary Case Studies Tutorials & Webinars
Product
Data Engine LLMs Platform Enterprise
Pricing Explore
Connect to our Discord channel
Morgan McGuire f1eb6322db
Merge pull request #134 from arampacha/add_eval_to_readme
3 years ago
e27ee527d8
Add model versioning (#122)
3 years ago
7693fbea27
Initial commit
3 years ago
34270ad1c9
add link to evaluation notebook in docs
3 years ago
nbs
212ab02817
model evaluation nb (#133)
3 years ago
38587071cf
tidies up docs
3 years ago
7693fbea27
Initial commit
3 years ago
e27ee527d8
Add model versioning (#122)
3 years ago
e27ee527d8
Add model versioning (#122)
3 years ago
e27ee527d8
Add model versioning (#122)
3 years ago
c439688d02
added nbdev workflow instructions to CONTRIBUTING.md
3 years ago
c0d368ef42
readme upd
3 years ago
9ad1e3ae6d
Update LICENSE
3 years ago
7693fbea27
Initial commit
3 years ago
c0d368ef42
readme upd
3 years ago
34270ad1c9
add link to evaluation notebook in docs
3 years ago
e27ee527d8
Add model versioning (#122)
3 years ago
e27ee527d8
Add model versioning (#122)
3 years ago
50aa5ac4b8
fix distrib2
3 years ago
50aa5ac4b8
fix distrib2
3 years ago
7693fbea27
Initial commit
3 years ago
e27ee527d8
Add model versioning (#122)
3 years ago
c22a3852ec
expscript w direct import
3 years ago
78b3b8c468
Adds Experiment Commands docs, re-arranged side bar, added einops>=0.3 requirement, small docs additions
3 years ago
b116f87a52
fix mit license classifier for pipy
3 years ago
Storage Buckets
Data Pipeline
Legend
DVC Managed File
Git Managed File
Metric
Stage File
External File

README.md

You have to be logged in to leave a comment. Sign In

Reformer Reproducibility Experiments

Fastai community entry to 2020 Papers With Code Reproducibility Challenge

Our Reproducibility Challenge Submission

  • Our OpenReview paper submission to the challenge can be found here
  • Our Weights & Biases Report, with interactive charts, is available here

Installation

Setup

If you don't already, its a good idea to install the package into a virtual environment

python3 -m venv my_env
source ./my_env/bin/activate

Install

Then you can install the package via pip:

pip install reformer-fastai

Or (even better) install latest version from github:

pip install git+git://github.com/arampacha/reformer_fastai.git

Contributing

This project used nbdev for all development, see their docs here to install nbdev and get started. Once you have nbdev installed we suggest you follow the suggested contributor workflow

Running Experiments

A pip installed version of this library is needed to run experiments. All experiments are run using the run_exp command, followed by the particular task name and then the parameters related to that task. run_exp --help will display a list of all parameters as well as a brief description. For brevity, an example of how to run a Reformer Language Model experiment is show below, a list of all experiment commands can be found here

Example: Reversible Language Model

Below is an example of the code used that generated the results in Section 4.4 "Effect of reversible layers" of our submission paper.

run_exp "lm_rev" \
        --n_epochs=10 \
        --bs=2 \
        --max_seq_len=4096 \
        --grad_accum=8 \
        --save_model=True  \
        --clip=0.5 \
        --seed=444 \
        --precision=2 \
        --do_wandb_logging=False \

Hyperparameters Used

The main hyperparameters used are documented in the Experiment Commands page and the Experiment Configs page. In addition, a full list of our hyperparameters can be found in the Run Sets tables of our Weights & Biases Report. To see these, navigate to the experiment of interests, click on the "Run Set" button under each chart and scroll across to find all hyperparameters.

Results

All full description of our results, including charts and tables can be found in our paper here on OpenReview. Our results are summarised as follows:

Claims around speed on longer sequences and reduced memory footprint were validated; as sequence length increased, Locality Sensitive Hashing ("LSH") Attention became faster and increasing the number of hashes improved performance. We could not achieve the performance of a traditional Transformer with Reformer. Some experiments were not run for as long as in the paper due to a lack of computational resources. Potentially the under-performance of our Reformer may be due to under-training, implementation differences or nuances in JAX vs Pytorch. Also, exploding gradients were encountered with mixed precision training and several model settings were found to be unstable depending on the random seed or learning rate.

Trained Models

All trained models from this project can be found in our Weights & Biases project here

Evaluation

An notebook example of running evaluation on one of our trained models saved on Weights & Biases can be found here

Resources

Author's Code and Resources

More Code

Data

Tokenizers used with these datasets can be found here

enwik8

WMT14

Explainers

Tip!

Press p or to see the previous file or, n or to see the next file

About

Fastai community entry to 2020 Reproducibility Challenge

Collaborators 1

Comments

Loading...