forked from f4t4nt/Berkeley-Crossword-Solver
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsetup.sh
27 lines (26 loc) · 1.8 KB
/
setup.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
# Install Dependencies
pip install scipy
mv DPR/transformers3 ./
pip install -e DPR/
mv transformers3 DPR/
pip install -e DPR/transformers3/
pip install -e DrQA/
pip install transformers
pip install wordsegment
pip install git+https://github.com/alexdej/puzpy.git
# Download checkpoints
mkdir -p checkpoints/byt5_reranker
mkdir -p checkpoints/biencoder/embeddings
mkdir -p checkpoints/gpt2_segmenter
wget https://huggingface.co/albertxu/Berkeley-Crossword-Solver/resolve/main/biencoder/dpr_biencoder.bin -O checkpoints/biencoder/dpr_biencoder.bin
wget https://huggingface.co/albertxu/Berkeley-Crossword-Solver/resolve/main/biencoder/wordlist.tsv -O checkpoints/biencoder/wordlist.tsv
wget https://huggingface.co/albertxu/Berkeley-Crossword-Solver/resolve/main/byt5_reranker/pytorch_model.bin -O checkpoints/byt5_reranker/pytorch_model.bin
wget https://huggingface.co/albertxu/Berkeley-Crossword-Solver/resolve/main/byt5_reranker/config.json -O checkpoints/byt5_reranker/config.json
wget https://huggingface.co/albertxu/Berkeley-Crossword-Solver/resolve/main/byt5_reranker/special_tokens_map.json -O checkpoints/byt5_reranker/special_tokens_map.json
wget https://huggingface.co/albertxu/Berkeley-Crossword-Solver/resolve/main/byt5_reranker/tokenizer_config.json -O checkpoints/byt5_reranker/tokenizer_config.json
wget https://huggingface.co/albertxu/Berkeley-Crossword-Solver/resolve/main/segmenter/pytorch_model.bin -O checkpoints/gpt2_segmenter/pytorch_model.bin
wget https://huggingface.co/albertxu/Berkeley-Crossword-Solver/resolve/main/segmenter/config.json -O checkpoints/gpt2_segmenter/config.json
# Download precomputed embeddings
for i in {0..3}; do
wget https://huggingface.co/albertxu/Berkeley-Crossword-Solver/resolve/main/biencoder/embeddings/embeddings.json_$i.pkl -O checkpoints/biencoder/embeddings/embeddings.json_$i.pkl
done