Skip to content

Commit d580e6e

Browse files
author
Hongtao Zhang
committed
style: apply yapf 0.31.0 formatting (CI lint fix)
- Collapse multi-line .format() call in _generate_dataset error message. - Add blank line before 'return _side_effect' in nested function in test.
1 parent 9018df0 commit d580e6e

2 files changed

Lines changed: 2 additions & 3 deletions

File tree

superbench/benchmarks/model_benchmarks/megatron_gpt3.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -661,9 +661,7 @@ def _generate_dataset(self): # noqa: C901
661661
logger.error(
662662
'data_prefix must end with "{}" and have a non-empty stem when '
663663
'dataset generation is required (got "{}"). preprocess_data.py '
664-
'always appends "{}" to --output-prefix.'.format(
665-
suffix, self._args.data_prefix, suffix
666-
)
664+
'always appends "{}" to --output-prefix.'.format(suffix, self._args.data_prefix, suffix)
667665
)
668666
self._result.set_return_code(ReturnCode.DATASET_GENERATION_FAILURE)
669667
return False

tests/benchmarks/model_benchmarks/test_megatron_gpt.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -203,6 +203,7 @@ def _side_effect(*_args, **_kwargs):
203203
p = Path(self._tmp_dir) / f'{prefix}{ext}'
204204
p.touch()
205205
created_files.append(p)
206+
206207
return _side_effect
207208

208209
self.addCleanup(lambda: [p.unlink() for p in created_files if p.is_file()])

0 commit comments

Comments
 (0)