From 9ee1dc53de3c3ae5c513e61cc8bbf257eb24dd22 Mon Sep 17 00:00:00 2001 From: niuliling123 <51102941+niuliling123@users.noreply.github.com> Date: Tue, 26 Apr 2022 18:58:36 +0800 Subject: [PATCH] update (#42248) --- python/paddle/fluid/reader.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/python/paddle/fluid/reader.py b/python/paddle/fluid/reader.py index 841c58821d7..3ea3af9ed1c 100644 --- a/python/paddle/fluid/reader.py +++ b/python/paddle/fluid/reader.py @@ -19,6 +19,7 @@ import numpy as np import threading import paddle import time +import copy from .framework import Program, Variable, program_guard, default_main_program, default_startup_program, _non_static_mode, cpu_places, _current_expected_place, _in_eager_without_dygraph_check from .executor import global_scope @@ -214,7 +215,7 @@ class AuToTune(object): return sub_dataset def get_autotune_loader(self): - loader = self.loader + loader = copy.copy(self.loader) batch_size = self.loader.batch_sampler.batch_size if isinstance(self.loader.batch_sampler, paddle.io.DistributedBatchSampler): -- GitLab