From 7f681eb5bfa93cb1743db10eea8075e722873f2e Mon Sep 17 00:00:00 2001 From: xjqbest <173596896@qq.com> Date: Fri, 29 May 2020 14:15:49 +0800 Subject: [PATCH] fix --- core/trainers/single_infer.py | 4 ++-- core/trainers/single_trainer.py | 4 ++-- models/rank/dnn/config.yaml | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/core/trainers/single_infer.py b/core/trainers/single_infer.py index 873ff010..0f1c92f3 100755 --- a/core/trainers/single_infer.py +++ b/core/trainers/single_infer.py @@ -229,7 +229,7 @@ class SingleInfer(TranspileTrainer): fetch_alias = [] fetch_period = int( envs.get_global_env("runner." + self._runner_name + - ".fetch_period", 20)) + ".print_interval", 20)) metrics = model_class.get_infer_results() if metrics: fetch_vars = metrics.values() @@ -260,7 +260,7 @@ class SingleInfer(TranspileTrainer): metrics_format = [] fetch_period = int( envs.get_global_env("runner." + self._runner_name + - ".fetch_period", 20)) + ".print_interval", 20)) metrics_format.append("{}: {{}}".format("batch")) for name, var in metrics.items(): metrics_varnames.append(var.name) diff --git a/core/trainers/single_trainer.py b/core/trainers/single_trainer.py index 274047a0..66daf402 100755 --- a/core/trainers/single_trainer.py +++ b/core/trainers/single_trainer.py @@ -226,7 +226,7 @@ class SingleTrainer(TranspileTrainer): fetch_alias = [] fetch_period = int( envs.get_global_env("runner." + self._runner_name + - ".fetch_period", 20)) + ".print_interval", 20)) metrics = model_class.get_metrics() if metrics: fetch_vars = metrics.values() @@ -253,7 +253,7 @@ class SingleTrainer(TranspileTrainer): fetch_alias = [] fetch_period = int( envs.get_global_env("runner." + self._runner_name + - ".fetch_period", 20)) + ".print_interval", 20)) metrics = model_class.get_metrics() if metrics: fetch_vars = metrics.values() diff --git a/models/rank/dnn/config.yaml b/models/rank/dnn/config.yaml index 57bb81d5..fd64935d 100755 --- a/models/rank/dnn/config.yaml +++ b/models/rank/dnn/config.yaml @@ -62,7 +62,7 @@ runner: save_inference_feed_varnames: [] # feed vars of save inference save_inference_fetch_varnames: [] # fetch vars of save inference init_model_path: "" # load model path - fetch_period: 10 + print_interval: 10 - name: runner2 class: single_infer # num of epochs -- GitLab