From 6e07bf08a2d5bddcba7bf5e653ffafb7fed1f765 Mon Sep 17 00:00:00 2001 From: LDOUBLEV Date: Fri, 19 Feb 2021 13:21:28 +0800 Subject: [PATCH] delete dist when export model --- deploy/slim/prune/export_prune_model.py | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/deploy/slim/prune/export_prune_model.py b/deploy/slim/prune/export_prune_model.py index 541273c8..29f7d211 100644 --- a/deploy/slim/prune/export_prune_model.py +++ b/deploy/slim/prune/export_prune_model.py @@ -25,23 +25,16 @@ sys.path.append(os.path.join(__dir__, '..', '..', '..')) sys.path.append(os.path.join(__dir__, '..', '..', '..', 'tools')) import paddle -import paddle.distributed as dist from ppocr.data import build_dataloader from ppocr.modeling.architectures import build_model -from ppocr.losses import build_loss -from ppocr.optimizer import build_optimizer + from ppocr.postprocess import build_post_process from ppocr.metrics import build_metric from ppocr.utils.save_load import init_model import tools.program as program -dist.get_world_size() - def main(config, device, logger, vdl_writer): - # init dist environment - if config['Global']['distributed']: - dist.init_parallel_env() global_config = config['Global'] -- GitLab