Skip to content

Commit

Permalink
cherrypick for PaddlePaddle#32640 :add profile and fix dataset hang i…
Browse files Browse the repository at this point in the history
…n heterps;test=develop
  • Loading branch information
danleifeng committed May 18, 2021
1 parent 7166cd0 commit 6e02a8d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion python/paddle/distributed/fleet/dataset/dataset.py
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ def _set_use_ps_gpu(self, use_ps_gpu):
"""
self.use_ps_gpu = use_ps_gpu

def _finish_to_run(self):
def _finish_to_run(self):
self.dataset.destroy_readers()

def _desc(self):
Expand Down
2 changes: 1 addition & 1 deletion python/paddle/fluid/executor.py
Original file line number Diff line number Diff line change
Expand Up @@ -1510,7 +1510,7 @@ def _run_from_dataset(self,
# in case of calling _set_use_ps_gpu explicitly
if dataset.use_ps_gpu is False:
dataset._set_use_ps_gpu(trainer.proto_desc.use_ps_gpu)
dataset._dynamic_adjust_before_train(trainer.proto_desc.thread_num)
dataset._dynamic_adjust_before_train(trainer.proto_desc.thread_num)

trainer_instance = self._default_executor.init_for_dataset(
program.desc, trainer._desc(), scope, dataset.dataset)
Expand Down

0 comments on commit 6e02a8d

Please sign in to comment.