Add a few examples of commands avaliable in ulmfit-multilingual

This commit is contained in:
Piotr Czapla
2019-04-20 14:34:26 +02:00
parent f9032ad846
commit f5306b4064
2 changed files with 16 additions and 1 deletions
+14 -1
View File
@@ -15,8 +15,21 @@ Model name: data/wiki/en-100/models/f60k/lstm_orig.m
$ python -m ulmfit cls --dataset-path data/imdb --base-lm-path data/wiki/${LANG}-100/models/f60k/lstm_orig.m \
--lang=${LANG} --name orig - train 20 --bs 18 --num-cls-epochs=4 --lr_sched=1cycle --label-smoothing-eps=0.1
```
You can re-evaluate classifiers by running
```
python -m ulmfit eval --glob="imdb/models/*/lstm_*.m"
```
The same command can be used to quickly trian multiple classifiers, by adding the `--name` parameter:
```
python -m ulmfit eval --glob="imdb/models/*/lstm_nl3.m" --name "nl3-my-test1" --num-cls-epochs 4 --label-smoothing-eps=0.1 --lr_sched=1cycle
```
To create a tar with model simply run
```
python -m ulmfit tar data/imdb/models/f60k/lstm_nl3.m
```
## data directory strucutre
+2
View File
@@ -0,0 +1,2 @@
# https://storage.googleapis.com/reddit_comments_polish/comments.csv.gz