From 0feecbd13c9cf700e80fe4dbce84c9b724cf248e Mon Sep 17 00:00:00 2001 From: wangyanfei01 Date: Wed, 9 Nov 2016 19:50:01 +0800 Subject: [PATCH] modify on docs --- doc/ui/cmd_argument/argument_outline.md | 11 ++++++++--- doc/ui/cmd_argument/detail_introduction.md | 14 +++++++++----- doc/ui/cmd_argument/use_case.md | 7 ++++--- paddle/trainer/Trainer.cpp | 3 ++- 4 files changed, 23 insertions(+), 12 deletions(-) diff --git a/doc/ui/cmd_argument/argument_outline.md b/doc/ui/cmd_argument/argument_outline.md index d6cc2c6ed..bafa5dfef 100644 --- a/doc/ui/cmd_argument/argument_outline.md +++ b/doc/ui/cmd_argument/argument_outline.md @@ -68,7 +68,7 @@ It looks like there are a lot of arguments. However, most of them are for develo -test_period +test_period_while_training √√ @@ -143,8 +143,13 @@ It looks like there are a lot of arguments. However, most of them are for develo -testing during trainingtest_all_data_in_one_period -√√ +testing during trainingtest_batches_while_training +√√√< + + + +testing during trainingtest_batches_while_end +√√√< diff --git a/doc/ui/cmd_argument/detail_introduction.md b/doc/ui/cmd_argument/detail_introduction.md index 07608e5ed..0628289db 100644 --- a/doc/ui/cmd_argument/detail_introduction.md +++ b/doc/ui/cmd_argument/detail_introduction.md @@ -109,9 +109,9 @@ - Load parameter from this pass to test. - type: int32 (default: -1). -* `--test_period` - - Run testing every test_period train batches. If not set, run testing each pass. - - type: int32 (default: 1000). +* `--test_period_while_training` + - Run test every so many train batches. If not 0, test log_period batches. If 0, test nothing. + - type: int32 (default: 0). * `--test_wait` - Whether to wait for parameter per pass if not exist. If set test_data_path in submitting environment of cluster, it will launch one process to perfom testing, so we need to set test_wait=1. Note that in the cluster submitting environment, this argument has been set True by default. @@ -121,8 +121,12 @@ - File that saves the model list when testing. It was set automatically when using cluster submitting environment after setting model_path. - type: string (default: "", null). -* `--test_all_data_in_one_period` - - This argument is usually used in testing period during traning. If true, all data will be tested in one test period. Otherwise (batch_size * log_peroid) data will be tested. +* `--test_batches_while_training` + - Test test_batches_while_training batches if test_batches_while_training != 0. If 0, test on all test data. + - type: bool (default: 1000). + +* `--test_batches_while_end` + - Test test_batches_while_end batches if test_batches_while_end != 0. If 0, test on all test data. - type: bool (default: 0). * `--predict_output_dir` diff --git a/doc/ui/cmd_argument/use_case.md b/doc/ui/cmd_argument/use_case.md index a6bfba29a..b24356010 100644 --- a/doc/ui/cmd_argument/use_case.md +++ b/doc/ui/cmd_argument/use_case.md @@ -10,9 +10,10 @@ paddle train \ --config=network_config \ --save_dir=output \ --trainer_count=COUNT \ #(default:1) - --test_period=M \ #(default:1000) - --test_all_data_in_one_period=true \ #(default:false) - --num_passes=N \ #(defalut:100) + --test_period_while_training=M \ #(default:0) + --test_batches_while_training=BATCHES \#(default:1000) + --test_batches_while_end=BATCHES \ #(default:0) + --num_passes=N \ #(defalut:100) --log_period=K \ #(default:100) --dot_period=1000 \ #(default:1) #[--show_parameter_stats_period=100] \ #(default:0) diff --git a/paddle/trainer/Trainer.cpp b/paddle/trainer/Trainer.cpp index 477813b47..107fa240c 100644 --- a/paddle/trainer/Trainer.cpp +++ b/paddle/trainer/Trainer.cpp @@ -49,7 +49,8 @@ P_DEFINE_int32(test_period_while_training, 0, " If not 0, test log_period batches." " If 0, test nothing."); P_DEFINE_int32(test_batches_while_training, 1000, - "test test_batches_while_training batches if test_period != 0." + "test test_batches_while_training batches if " + "test_batches_while_training != 0." " If 0, test on all test data"); P_DEFINE_int32(test_batches_while_end, 0, "test test_batches_while_end batches at pass end." -- GitLab