diff --git a/deepes/benchmark/cartpole_config.prototxt b/deepes/benchmark/cartpole_config.prototxt index 9d8b7725d02897956cdf2b74bb8aa2e3fb346f46..03cc5fbf4f337d4dcce87a67004fb115aa13ec83 100644 --- a/deepes/benchmark/cartpole_config.prototxt +++ b/deepes/benchmark/cartpole_config.prototxt @@ -11,5 +11,5 @@ optimizer { epsilon: 1e-08 } async_es { - model_iter_id: 99 + model_iter_id: 0 } diff --git a/deepes/src/paddle/async_es_agent.cc b/deepes/src/paddle/async_es_agent.cc index b120eeca8e9bd3c12aa54883b3e425b6c4b37fdf..d9cdfd9ae029df50ff987c8b9f83dd123145a2bb 100644 --- a/deepes/src/paddle/async_es_agent.cc +++ b/deepes/src/paddle/async_es_agent.cc @@ -30,7 +30,7 @@ AsyncESAgent::~AsyncESAgent() { bool AsyncESAgent::_save() { bool success = true; if (_is_sampling_agent) { - LOG(ERROR) << "[DeepES] Original AsyncESAgent cannot call `save`.Please use cloned AsyncESAgent."; + LOG(ERROR) << "[DeepES] Cloned AsyncESAgent cannot call `save`.Please use cloned AsyncESAgent."; success = false; return success; } @@ -43,10 +43,7 @@ bool AsyncESAgent::_save() { time (&rawtime); timeinfo = localtime(&rawtime); - strftime(buffer,sizeof(buffer),"%d-%m-%Y-%H:%M:%S",timeinfo); - std::string current_time(buffer); - std::string model_name = current_time + "-model_iter_id-"+ std::to_string(model_iter_id); - model_name = "model_iter_id-"+ std::to_string(model_iter_id); + std::string model_name = "model_iter_id-"+ std::to_string(model_iter_id); std::string model_path = _config->async_es().model_warehouse() + "/" + model_name; LOG(INFO) << "[save]model_path: " << model_path; _predictor->SaveOptimizedModel(model_path, LiteModelType::kProtobuf);