mirror of
https://github.com/wassname/pytorch-lightning.git
synced 2026-09-09 11:32:07 +08:00
indents
This commit is contained in:
@@ -294,8 +294,8 @@ class TrainerEvaluationLoopMixin(ABC):
|
||||
position = 2 * self.process_position + (not test)
|
||||
desc = 'Testing' if test else 'Validating'
|
||||
pbar = tqdm(desc=desc, total=max_batches, leave=test, position=position,
|
||||
disable=not self.show_progress_bar, dynamic_ncols=True,
|
||||
unit='batch', file=sys.stdout)
|
||||
disable=not self.show_progress_bar, dynamic_ncols=True,
|
||||
unit='batch', file=sys.stdout)
|
||||
setattr(self, f'{"test" if test else "val"}_progress_bar', pbar)
|
||||
|
||||
# run evaluation
|
||||
|
||||
@@ -829,8 +829,8 @@ class Trainer(TrainerIOMixin,
|
||||
|
||||
# init progress bar
|
||||
pbar = tqdm(leave=True, position=2 * self.process_position,
|
||||
disable=not self.show_progress_bar, dynamic_ncols=True, unit='batch',
|
||||
file=sys.stdout)
|
||||
disable=not self.show_progress_bar, dynamic_ncols=True, unit='batch',
|
||||
file=sys.stdout)
|
||||
self.main_progress_bar = pbar
|
||||
|
||||
# clear cache before training
|
||||
|
||||
Reference in New Issue
Block a user