From d6babfb8f3dc707473345664eb145128c6587272 Mon Sep 17 00:00:00 2001 From: Reuben Morais Date: Mon, 1 Apr 2019 08:45:42 -0300 Subject: [PATCH] Speed up training tests and make sure they fully converge --- bin/run-tc-ldc93s1_checkpoint.sh | 2 +- bin/run-tc-ldc93s1_new.sh | 9 ++++----- bin/run-tc-ldc93s1_singleshotinference.sh | 4 ++-- bin/run-tc-ldc93s1_tflite.sh | 4 ++-- tc-train-tests.sh | 6 +++--- 5 files changed, 12 insertions(+), 13 deletions(-) diff --git a/bin/run-tc-ldc93s1_checkpoint.sh b/bin/run-tc-ldc93s1_checkpoint.sh index e8fdee8f..de92a304 100755 --- a/bin/run-tc-ldc93s1_checkpoint.sh +++ b/bin/run-tc-ldc93s1_checkpoint.sh @@ -16,7 +16,7 @@ python -u DeepSpeech.py --noshow_progressbar --noearly_stop \ --train_files ${ldc93s1_csv} --train_batch_size 1 \ --dev_files ${ldc93s1_csv} --dev_batch_size 1 \ --test_files ${ldc93s1_csv} --test_batch_size 1 \ - --n_hidden 494 --epoch -1 --random_seed 4567 --default_stddev 0.046875 \ + --n_hidden 100 --epoch -1 \ --max_to_keep 1 --checkpoint_dir '/tmp/ckpt' \ --learning_rate 0.001 --dropout_rate 0.05 \ --lm_binary_path 'data/smoke_test/vocab.pruned.lm' \ diff --git a/bin/run-tc-ldc93s1_new.sh b/bin/run-tc-ldc93s1_new.sh index cee8ede4..f1e64d3e 100755 --- a/bin/run-tc-ldc93s1_new.sh +++ b/bin/run-tc-ldc93s1_new.sh @@ -14,12 +14,11 @@ fi; python -u DeepSpeech.py --noshow_progressbar --noearly_stop \ --train_files ${ldc93s1_csv} --train_batch_size 1 \ - --train_cached_features_path "/tmp/ldc93s1.hdf5" \ + --train_cached_features_path '/tmp/ldc93s1_cache' \ --dev_files ${ldc93s1_csv} --dev_batch_size 1 \ --test_files ${ldc93s1_csv} --test_batch_size 1 \ - --n_hidden 494 --epoch $epoch_count --random_seed 4567 \ - --default_stddev 0.046875 --max_to_keep 1 \ - --checkpoint_dir '/tmp/ckpt' \ + --n_hidden 100 --epoch $epoch_count \ + --max_to_keep 1 --checkpoint_dir '/tmp/ckpt' \ --learning_rate 0.001 --dropout_rate 0.05 --export_dir '/tmp/train' \ --lm_binary_path 'data/smoke_test/vocab.pruned.lm' \ - --lm_trie_path 'data/smoke_test/vocab.trie' \ + --lm_trie_path 'data/smoke_test/vocab.trie' diff --git a/bin/run-tc-ldc93s1_singleshotinference.sh b/bin/run-tc-ldc93s1_singleshotinference.sh index 7f6d2ba2..25e04f7d 100755 --- a/bin/run-tc-ldc93s1_singleshotinference.sh +++ b/bin/run-tc-ldc93s1_singleshotinference.sh @@ -14,7 +14,7 @@ python -u DeepSpeech.py --noshow_progressbar --noearly_stop \ --train_files ${ldc93s1_csv} --train_batch_size 1 \ --dev_files ${ldc93s1_csv} --dev_batch_size 1 \ --test_files ${ldc93s1_csv} --test_batch_size 1 \ - --n_hidden 494 --epoch 1 --random_seed 4567 --default_stddev 0.046875 \ + --n_hidden 100 --epoch 1 \ --max_to_keep 1 --checkpoint_dir '/tmp/ckpt' --checkpoint_secs 0 \ --learning_rate 0.001 --dropout_rate 0.05 \ --lm_binary_path 'data/smoke_test/vocab.pruned.lm' \ @@ -24,7 +24,7 @@ python -u DeepSpeech.py --noshow_progressbar --noearly_stop \ --train_files ${ldc93s1_csv} --train_batch_size 1 \ --dev_files ${ldc93s1_csv} --dev_batch_size 1 \ --test_files ${ldc93s1_csv} --test_batch_size 1 \ - --n_hidden 494 --epoch 1 --random_seed 4567 --default_stddev 0.046875 \ + --n_hidden 100 --epoch 1 \ --max_to_keep 1 --checkpoint_dir '/tmp/ckpt' --checkpoint_secs 0 \ --learning_rate 0.001 --dropout_rate 0.05 \ --lm_binary_path 'data/smoke_test/vocab.pruned.lm' \ diff --git a/bin/run-tc-ldc93s1_tflite.sh b/bin/run-tc-ldc93s1_tflite.sh index 8a9f44ea..d99b4b59 100755 --- a/bin/run-tc-ldc93s1_tflite.sh +++ b/bin/run-tc-ldc93s1_tflite.sh @@ -11,10 +11,10 @@ if [ ! -f "${ldc93s1_dir}/ldc93s1.csv" ]; then fi; python -u DeepSpeech.py --noshow_progressbar \ - --n_hidden 494 \ + --n_hidden 100 \ --checkpoint_dir '/tmp/ckpt' \ --export_dir '/tmp/train_tflite' \ --lm_binary_path 'data/smoke_test/vocab.pruned.lm' \ --lm_trie_path 'data/smoke_test/vocab.trie' \ --notrain --notest \ - --export_tflite --nouse_seq_length \ + --export_tflite --nouse_seq_length diff --git a/tc-train-tests.sh b/tc-train-tests.sh index ec74b03d..a08624b4 100644 --- a/tc-train-tests.sh +++ b/tc-train-tests.sh @@ -58,8 +58,8 @@ LD_LIBRARY_PATH=${PY37_LDPATH}:$LD_LIBRARY_PATH pip install --verbose --only-bin pushd ${HOME}/DeepSpeech/ds/ # Run twice to test preprocessed features - time ./bin/run-tc-ldc93s1_new.sh 104 - time ./bin/run-tc-ldc93s1_new.sh 105 + time ./bin/run-tc-ldc93s1_new.sh 199 + time ./bin/run-tc-ldc93s1_new.sh 200 time ./bin/run-tc-ldc93s1_tflite.sh popd @@ -75,7 +75,7 @@ if [ ! -z "${CONVERT_GRAPHDEF_MEMMAPPED}" ]; then fi; pushd ${HOME}/DeepSpeech/ds/ - time ./bin/run-tc-ldc93s1_checkpoint.sh 105 + time ./bin/run-tc-ldc93s1_checkpoint.sh 200 popd deactivate