提交 04fb1fc1 编写于 作者: Y Yu Yang 提交者: GitHub

Merge pull request #891 from backyes/sparse_bug

[Sparse Bug]  Test and sparse_remote_update can not co-exsit, crash trainer if necessary
......@@ -46,6 +46,12 @@ Tester::Tester(const std::shared_ptr<TrainerConfigHelper>& config,
gradientMachine_(gradientMachine),
parameterUpdater_(parameterUpdater),
testDataProvider_(testDataProvider) {
if (config_->getOptConfig().use_sparse_remote_updater()) {
LOG(FATAL) << "It's prohibited to set sparse_remote_update "
<< "when doing train and test jobs in the same "
<< "process. You could run paddle --job=test in "
<< "a separate process.";
}
testEvaluator_.reset(gradientMachine_->makeEvaluator());
if (intconfig_->distributeTest) {
testParameterClient_.reset(new ParameterClient2(true));
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册