提交 f4c323f5 编写于 作者: X xjqbest

fix

上级 15f79444
...@@ -289,7 +289,7 @@ class SingleInfer(TranspileTrainer): ...@@ -289,7 +289,7 @@ class SingleInfer(TranspileTrainer):
def load(self, is_fleet=False): def load(self, is_fleet=False):
name = "runner." + self._runner_name + "." name = "runner." + self._runner_name + "."
dirname = envs.get_global_env("epoch.init_model_path", None) dirname = envs.get_global_env("epoch.init_model_path", None)
if dirname is None: if dirname is None or dirname == "":
return return
print("single_infer going to load ", dirname) print("single_infer going to load ", dirname)
if is_fleet: if is_fleet:
......
...@@ -288,7 +288,7 @@ class SingleTrainer(TranspileTrainer): ...@@ -288,7 +288,7 @@ class SingleTrainer(TranspileTrainer):
def load(self, is_fleet=False): def load(self, is_fleet=False):
dirname = envs.get_global_env( dirname = envs.get_global_env(
"runner." + self._runner_name + ".init_model_path", None) "runner." + self._runner_name + ".init_model_path", None)
if dirname is None: if dirname is None or dirname == "":
return return
print("going to load ", dirname) print("going to load ", dirname)
if is_fleet: if is_fleet:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册