未验证 提交 b6822c84 编写于 作者: M MRXLT 提交者: GitHub

Merge branch 'develop' into develop

...@@ -92,9 +92,12 @@ def save_model(server_model_folder, ...@@ -92,9 +92,12 @@ def save_model(server_model_folder,
fetch_var.shape.extend(tmp_shape) fetch_var.shape.extend(tmp_shape)
config.fetch_var.extend([fetch_var]) config.fetch_var.extend([fetch_var])
cmd = "mkdir -p {}".format(client_config_folder) try:
save_dirname = os.path.normpath(client_config_folder)
os.system(cmd) os.makedirs(save_dirname)
except OSError as e:
if e.errno != errno.EEXIST:
raise
with open("{}/serving_client_conf.prototxt".format(client_config_folder), with open("{}/serving_client_conf.prototxt".format(client_config_folder),
"w") as fout: "w") as fout:
fout.write(str(config)) fout.write(str(config))
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册