Permalink
Cannot retrieve contributors at this time
Name already in use
A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
saliency-based-citation/setup.sh
Go to fileThis commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
executable file
34 lines (27 sloc)
1.2 KB
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Create a new Anaconda environment called citation with python 3.9 | |
conda create --name citation python=3.9 | |
# Activate the environment | |
source activate citation | |
# Install the required packages from requirements.txt | |
pip install -r requirements.txt | |
# Download the dataset | |
wget https://huggingface.co/datasets/princeton-nlp/ALCE-data/resolve/main/ALCE-data.tar | |
tar xvf ALCE-data.tar | |
mv ALCE-data data | |
echo "deleting tar file..." | |
rm ALCE-data.tar | |
wget https://storage.googleapis.com/gresearch/xor_attriqa/xor_attriqa.zip | |
unzip xor_attriqa.zip | |
echo "deleting zip file..." | |
rm xor_attriqa.zip | |
## NOTE: Not Necessary since the dataset already contains the retrieved results | |
# Download the retrievers | |
# wget -P faiss_index https://dl.fbaipublicfiles.com/sphere/sphere_sparse_index.tar.gz | |
# tar -xzvf faiss_index/sphere_sparse_index.tar.gz -C faiss_index | |
# export BM25_SPHERE_PATH=$PWD/faiss_index | |
# wget https://dl.fbaipublicfiles.com/dpr/wikipedia_split/psgs_w100.tsv.gz | |
# gzip -xzvf psgs_w100.tsv.gz | |
# export DPR_WIKI_TSV=$PWD/psgs_w100.tsv | |
# wget https://huggingface.co/datasets/princeton-nlp/gtr-t5-xxl-wikipedia-psgs_w100-index/resolve/main/gtr_wikipedia_index.pkl | |
# export GTR_EMB=$PWD/gtr_wikipedia_index.pkl |