From 85f65ce76f664e5b4fc50f6ee6351a00b7a8dd18 Mon Sep 17 00:00:00 2001 From: kangguangli Date: Mon, 13 Feb 2023 13:22:20 +0000 Subject: [PATCH] fix paddle2.4 hang problem --- ppcls/static/train.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/ppcls/static/train.py b/ppcls/static/train.py index eed68d38..53566267 100755 --- a/ppcls/static/train.py +++ b/ppcls/static/train.py @@ -171,7 +171,10 @@ def main(args): compiled_train_prog = train_prog if eval_dataloader is not None: - compiled_eval_prog = program.compile(config, eval_prog) + if not global_config.get("is_distributed", True): + compiled_eval_prog = program.compile(config, eval_prog) + else: + compiled_eval_prog = eval_prog for epoch_id in range(global_config["epochs"]): # 1. train with train dataset -- GitLab