diff options
-rwxr-xr-x | get_data.sh | 1 | ||||
-rwxr-xr-x | get_embeddings.sh | 7 |
2 files changed, 5 insertions, 3 deletions
diff --git a/get_data.sh b/get_data.sh index 2d04678..4f97ad5 100755 --- a/get_data.sh +++ b/get_data.sh | |||
@@ -67,6 +67,7 @@ mv "${ROOT}"/*.def "${READY}" | |||
67 | echo "Downloading dictionaries" | 67 | echo "Downloading dictionaries" |
68 | 68 | ||
69 | DICT="${ROOT}/dictionaries" | 69 | DICT="${ROOT}/dictionaries" |
70 | mkdir -p "${DICT}" | ||
70 | 71 | ||
71 | wget -nc -q https://object.pouta.csc.fi/OPUS-OpenSubtitles/v2018/dic/en-sq.dic.gz -P "${DICT}" # English - Albanian | 72 | wget -nc -q https://object.pouta.csc.fi/OPUS-OpenSubtitles/v2018/dic/en-sq.dic.gz -P "${DICT}" # English - Albanian |
72 | wget -nc -q https://object.pouta.csc.fi/OPUS-OpenSubtitles/v2018/dic/bg-en.dic.gz -P "${DICT}" # Bulgarian - English | 73 | wget -nc -q https://object.pouta.csc.fi/OPUS-OpenSubtitles/v2018/dic/bg-en.dic.gz -P "${DICT}" # Bulgarian - English |
diff --git a/get_embeddings.sh b/get_embeddings.sh index daf839b..47a7a8e 100755 --- a/get_embeddings.sh +++ b/get_embeddings.sh | |||
@@ -25,6 +25,7 @@ set -o errexit -o pipefail -o noclobber -o nounset | |||
25 | 25 | ||
26 | ROOT="$(pwd)" | 26 | ROOT="$(pwd)" |
27 | EMBS="${ROOT}/embeddings" | 27 | EMBS="${ROOT}/embeddings" |
28 | DICT="${ROOT}/dictionaries" | ||
28 | mkdir -p "${EMBS}" | 29 | mkdir -p "${EMBS}" |
29 | 30 | ||
30 | echo "Downloading embeddings" | 31 | echo "Downloading embeddings" |
@@ -58,15 +59,15 @@ if [ ! "$(ls -A "${ROOT}/vecmap/")" ]; then | |||
58 | echo "VecMap directory seems empty, did you run git submodule init && git submodule update?"; exit | 59 | echo "VecMap directory seems empty, did you run git submodule init && git submodule update?"; exit |
59 | fi | 60 | fi |
60 | 61 | ||
61 | if [ ! -d "${ROOT}/dictionaries" ]; then | 62 | if [ ! -d "${DICT}" ]; then |
62 | echo "Dictionaries directory does not exist, did you run ./get_data.sh?"; exit | 63 | echo "Dictionaries directory does not exist, did you run ./get_data.sh?"; exit |
63 | fi | 64 | fi |
64 | 65 | ||
65 | if [ ! "$(ls -A "${ROOT}/dictionaries/")" ]; then | 66 | if [ ! "$(ls -A "${DICT}")" ]; then |
66 | echo "Dictionaries directory seems empty, did you run ./get_data.sh?"; exit | 67 | echo "Dictionaries directory seems empty, did you run ./get_data.sh?"; exit |
67 | fi | 68 | fi |
68 | 69 | ||
69 | TRAIN_DIC_DIR="${ROOT}/dictionaries/train" | 70 | TRAIN_DIC_DIR="${DICT}/train" |
70 | MAP_TO="${ROOT}/bilingual_embeddings" | 71 | MAP_TO="${ROOT}/bilingual_embeddings" |
71 | 72 | ||
72 | mkdir -p "${MAP_TO}" | 73 | mkdir -p "${MAP_TO}" |