forked from gsingers/search_with_machine_learning_course
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathexecute_me.sh
executable file
·13 lines (11 loc) · 1.53 KB
/
execute_me.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
python week3/createContentTrainingData.py --output /workspace/datasets/categories/output.fasttext
wc -l /workspace/datasets/categories/output.fasttext
shuf -n `wc -l /workspace/datasets/categories/output.fasttext | cut -d' ' -f 1` /workspace/datasets/categories/output.fasttext > /workspace/datasets/categories/output.fasttext.shuffled
#head -$((`(wc -l /workspace/datasets/categories/output.fasttext | cut -d' ' -f 1)`/2)) /workspace/datasets/categories/output.fasttext.shuffled > /workspace/datasets/categories/output.fasttext.shuffled.train
#tail -$((`(wc -l /workspace/datasets/categories/output.fasttext | cut -d' ' -f 1)`/2)) /workspace/datasets/categories/output.fasttext.shuffled > /workspace/datasets/categories/output.fasttext.shuffled.test
head -10000 /workspace/datasets/categories/output.fasttext.shuffled > /workspace/datasets/categories/output.fasttext.shuffled.train
tail -10000 /workspace/datasets/categories/output.fasttext.shuffled > /workspace/datasets/categories/output.fasttext.shuffled.test
~/fastText-0.9.2/fasttext supervised -input /workspace/datasets/categories/output.fasttext.shuffled.train -output /workspace/model/model_default
~/fastText-0.9.2/fasttext test /workspace/model/model_default.bin /workspace/datasets/categories/output.fasttext.shuffled.test
~/fastText-0.9.2/fasttext supervised -input /workspace/datasets/categories/output.fasttext.shuffled.train -output /workspace/model/model_default -epoch 25
~/fastText-0.9.2/fasttext test /workspace/model/model_default.bin /workspace/datasets/categories/output.fasttext.shuffled.test