提交 5d8f2813 编写于 作者: P peizhilin

restore the memory mode

test=develop
上级 33b7821a
...@@ -44,7 +44,7 @@ class LoadCombineOp : public framework::OperatorBase { ...@@ -44,7 +44,7 @@ class LoadCombineOp : public framework::OperatorBase {
LoadParamsFromBuffer(scope, place, &fin, load_as_fp16, out_var_names); LoadParamsFromBuffer(scope, place, &fin, load_as_fp16, out_var_names);
} else { } else {
PADDLE_ENFORCE(!filename.empty(), "Cannot load file from memory"); PADDLE_ENFORCE(!filename.empty(), "Cannot load file from memory");
std::stringstream fin(filename, std::ios::binary); std::stringstream fin(filename);
LoadParamsFromBuffer(scope, place, &fin, load_as_fp16, out_var_names); LoadParamsFromBuffer(scope, place, &fin, load_as_fp16, out_var_names);
} }
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册