提交 81cad374 编写于 作者: D dzhwinter

"remove comments"

上级 3b1294ae
...@@ -5,7 +5,6 @@ namespace paddle { ...@@ -5,7 +5,6 @@ namespace paddle {
namespace optimizer { namespace optimizer {
void SGDOptimizer::set_weight(Tensor *p) { void SGDOptimizer::set_weight(Tensor *p) {
// ParameterOptimizer::set_weight(p);
parameter_ = p; parameter_ = p;
size_t size = p->size(); size_t size = p->size();
// TODO: fix it with align aware allocator bind to Tensor // TODO: fix it with align aware allocator bind to Tensor
...@@ -44,8 +43,6 @@ const char *SGDOptimizer::SerializeState() { ...@@ -44,8 +43,6 @@ const char *SGDOptimizer::SerializeState() {
state.set_version(kOptimizerVersion); state.set_version(kOptimizerVersion);
TensorToProto(*parameter_, state.add_data()); TensorToProto(*parameter_, state.add_data());
TensorToProto(*momentums_, state.add_data()); TensorToProto(*momentums_, state.add_data());
// state.add_data(param_proto);
// state.add_data(momentum_proto);
state.add_hyperparam(momentum_); state.add_hyperparam(momentum_);
return state.SerializeAsString().c_str(); return state.SerializeAsString().c_str();
} }
......
...@@ -87,7 +87,6 @@ message OptimizerState { ...@@ -87,7 +87,6 @@ message OptimizerState {
message OptimizerConfig { message OptimizerConfig {
// common config of optimizer // common config of optimizer
// algorithm config, type : string
enum Optimizer { enum Optimizer {
SGD = 1; SGD = 1;
Adadelta = 2; Adadelta = 2;
...@@ -100,7 +99,6 @@ message OptimizerConfig { ...@@ -100,7 +99,6 @@ message OptimizerConfig {
optional AdagradConfig adagrad = 5; optional AdagradConfig adagrad = 5;
optional AdamConfig adam = 6; optional AdamConfig adam = 6;
// learning rate runtime policy config
enum LrPolicy { enum LrPolicy {
ConstLr = 0; ConstLr = 0;
LinearLr = 1; LinearLr = 1;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册