aboutsummaryrefslogtreecommitdiffstats
path: root/run_semb.sh
blob: 7256fbfbf3884000c0330b0884e7a81ed565aabd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/bin/bash

set -o errexit -o pipefail -o noclobber -o nounset

ROOTDIR="$(pwd)"
ready_vectors_path="${ROOTDIR}/bilingual_embeddings"
wordnets_path="${ROOTDIR}/wordnets/ready"

for i in  en,bg en,el en,it, en,ro, en,sl en,sq, bg,el bg,it bg,ro el,it el,ro el,sq it,ro ro,sl ro,sq; do
    IFS=',' read -r source_lang target_lang <<< "${i}"
    echo "SEMB: ${source_lang} - ${target_lang}"
    source_vec="${ready_vectors_path}/${source_lang}_to_${target_lang}.vec"
    target_vec="${ready_vectors_path}/${target_lang}_to_${source_lang}.vec"
    source_def="${wordnets_path}/${source_lang}_to_${target_lang}.def"
    target_def="${wordnets_path}/${target_lang}_to_${source_lang}.def"
    python "${ROOTDIR}/sentence_embedding.py" "${source_lang}" "${target_lang}" "${source_vec}" "${target_vec}" "${source_def}" "${target_def}" all -n 1000 -b
    sleep 5
done