Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds requirements.txt #33

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -102,3 +102,5 @@ venv.bak/

# mypy
.mypy_cache/

log/
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
# finetune-transformer-lm
Code and model for the paper "Improving Language Understanding by Generative Pre-Training"

Before running this code, you need to:
1. `pip install -r requirements.txt`. If you lack a GPU, see `requirements.txt` for necessary modifications
2. `python -m spacy download en`
3. Export the "val set" and "test set" from the ROC stories corpus (see below) as CSV files
with the default filenames and place them in a `data` subdirectory under this repository.

Currently this code implements the ROCStories Cloze Test result reported in the paper by running:
`python train.py --dataset rocstories --desc rocstories --submit --analysis --data_dir [path to data here]`

Expand Down
11 changes: 11 additions & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# older versions of these dependencies may work
# these are simply the newest versions at the time this file was made
joblib>=0.12.5
numpy>=1.15.4
# change to just tensorflow if you don't have a GPU
tensorflow-gpu>=1.11.0
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The code in this repo is not compatible with the latest TF, so some restriction here is needed.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, and good point! Unfortunately, I am no longer working with this software, so I don't have the time to figure out what an appropriate upper bound is (and this repository doesn't seem to be maintained, anyhow).

tqdm>=4.28.1
scikit-learn>=0.19.2
pandas>=0.23.4
ftfy>=5.5.0
spacy>=2.0.16