From 013c12ffd32036d3b330862a9283af426be938a3 Mon Sep 17 00:00:00 2001 From: chengmo Date: Wed, 13 May 2020 18:29:03 +0800 Subject: [PATCH] fix bug --- core/trainers/transpiler_trainer.py | 4 ++-- core/utils/envs.py | 6 ------ 2 files changed, 2 insertions(+), 8 deletions(-) diff --git a/core/trainers/transpiler_trainer.py b/core/trainers/transpiler_trainer.py index f9d77f47..1904e27b 100755 --- a/core/trainers/transpiler_trainer.py +++ b/core/trainers/transpiler_trainer.py @@ -60,7 +60,7 @@ class TranspileTrainer(Trainer): if idx >= 9: break print("--- DataLoader Debug Mode End , show pre 10 data ---") - exit 0 + exit(0) reader_class = envs.lazy_instance_by_fliename(reader_class, class_name) reader_ins = reader_class(self._config_yaml) @@ -116,7 +116,7 @@ class TranspileTrainer(Trainer): os.system("cat {} | {} | head -10".format(file_list[0], pipe_cmd)) print( "--- Dataset Debug Mode End , show pre 10 data of {}---".format(file_list[0])) - exit 0 + exit(0) return dataset diff --git a/core/utils/envs.py b/core/utils/envs.py index 1c3b6c45..50628dd5 100755 --- a/core/utils/envs.py +++ b/core/utils/envs.py @@ -176,12 +176,6 @@ def get_platform(): return "WINDOWS" -<< << << < HEAD: fleet_rec/core/utils/envs.py - -== == == = ->>>>>> > upstream/develop: core/utils/envs.py - - def find_free_port(): def __free_port(): with closing(socket.socket(socket.AF_INET, -- GitLab