Repository: pytorch
Issue: Fix docstring errors in default_hooks.py, post_localSGD_hook.py, debugging_hooks.py, utils.py, hierarchical_model_averager.py, optimizer_overlap_hooks.py, mixed_precision_hooks.py, quantization_hooks.py, ddp_zero_hook.py, __init__.py, powerSGD_hook.py, averagers.py
Labels: module: docs,triaged,medium,docathon-h2-2023

Please fix the following issues. To test locally, run: 
 ```
pydocstyle path-to-file --count
```
Run this command before and after fixing the errors. This command prints out the number of errors at the end of the output. Paste the output to your PR description with the number before and after. 
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/ddp_zero_hook.py`, **Entity**: `_perform_local_step`, **Line**: 26, **Description**: First line should be in imperative mood (perhaps 'Perform', not 'Performs')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/ddp_zero_hook.py`, **Entity**: `_save_ddp_bucket_info`, **Line**: 100, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/ddp_zero_hook.py`, **Entity**: `_save_ddp_bucket_info`, **Line**: 100, **Description**: First line should end with a period (not 'e')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/ddp_zero_hook.py`, **Entity**: `_save_ddp_bucket_info`, **Line**: 100, **Description**: First line should be in imperative mood (perhaps 'Save', not 'Saves')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/ddp_zero_hook.py`, **Entity**: `_hook_with_zero_step_setup`, **Line**: 132, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/ddp_zero_hook.py`, **Entity**: `_hook_with_zero_step_setup`, **Line**: 132, **Description**: First line should end with a period (not 'd')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/ddp_zero_hook.py`, **Entity**: `_hook_with_zero_step_setup`, **Line**: 132, **Description**: First line should be in imperative mood (perhaps 'Encapsulate', not 'Encapsulates')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/ddp_zero_hook.py`, **Entity**: `hook_with_zero_step`, **Line**: 174, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/ddp_zero_hook.py`, **Entity**: `hook_with_zero_step`, **Line**: 174, **Description**: First line should end with a period (not '`')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/ddp_zero_hook.py`, **Entity**: `hook_with_zero_step`, **Line**: 174, **Description**: First line should be in imperative mood (perhaps 'Modify', not 'Modifies')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/ddp_zero_hook.py`, **Entity**: `hook_with_zero_fn`, **Line**: 246, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/ddp_zero_hook.py`, **Entity**: `hook_with_zero_fn`, **Line**: 246, **Description**: First line should end with a period (not 'd')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/ddp_zero_hook.py`, **Entity**: `hook_with_zero_fn`, **Line**: 246, **Description**: First line should be in imperative mood (perhaps 'Return', not 'Returns')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/ddp_zero_hook.py`, **Entity**: `hook_with_zero_step_interleaved`, **Line**: 333, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/ddp_zero_hook.py`, **Entity**: `hook_with_zero_step_interleaved`, **Line**: 333, **Description**: First line should end with a period (not '`')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/ddp_zero_hook.py`, **Entity**: `hook_with_zero_step_interleaved`, **Line**: 333, **Description**: First line should be in imperative mood (perhaps 'Modify', not 'Modifies')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/ddp_zero_hook.py`, **Entity**: `hook_with_zero_interleaved_fn`, **Line**: 406, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/ddp_zero_hook.py`, **Entity**: `hook_with_zero_interleaved_fn`, **Line**: 406, **Description**: First line should end with a period (not 'd')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/ddp_zero_hook.py`, **Entity**: `hook_with_zero_interleaved_fn`, **Line**: 406, **Description**: First line should be in imperative mood (perhaps 'Return', not 'Returns')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/ddp_zero_hook.py`, **Entity**: `zero_step`, **Line**: 421, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/ddp_zero_hook.py`, **Entity**: `zero_step`, **Line**: 421, **Description**: First line should end with a period (not '`')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/ddp_zero_hook.py`, **Entity**: `zero_step`, **Line**: 421, **Description**: First line should be in imperative mood (perhaps 'Perform', not 'Performs')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/debugging_hooks.py`, **Entity**: `noop_hook`, **Line**: 10, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/debugging_hooks.py`, **Entity**: `noop_hook`, **Line**: 10, **Description**: First line should end with a period (not ',')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/debugging_hooks.py`, **Entity**: `noop_hook`, **Line**: 10, **Description**: First line should be in imperative mood; try rephrasing (found 'This')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/default_hooks.py`, **Entity**: `_allreduce_fut`, **Line**: 11, **Description**: Use """triple double quotes""" (found "-quotes)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/default_hooks.py`, **Entity**: `allreduce_hook`, **Line**: 27, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/default_hooks.py`, **Entity**: `allreduce_hook`, **Line**: 27, **Description**: First line should end with a period (not '`')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/default_hooks.py`, **Entity**: `allreduce_hook`, **Line**: 27, **Description**: First line should be in imperative mood; try rephrasing (found 'This')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/default_hooks.py`, **Entity**: `fp16_compress_hook`, **Line**: 46, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/default_hooks.py`, **Entity**: `fp16_compress_hook`, **Line**: 46, **Description**: First line should end with a period (not 'n')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/default_hooks.py`, **Entity**: `fp16_compress_hook`, **Line**: 46, **Description**: First line should be in imperative mood; try rephrasing (found 'This')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/default_hooks.py`, **Entity**: `fp16_compress_wrapper`, **Line**: 115, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/default_hooks.py`, **Entity**: `fp16_compress_wrapper`, **Line**: 115, **Description**: First line should end with a period (not 'n')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/default_hooks.py`, **Entity**: `fp16_compress_wrapper`, **Line**: 115, **Description**: First line should be in imperative mood; try rephrasing (found 'This')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/__init__.py`, **Entity**: `_powerSGD_comm_hook_wrapper`, **Line**: 27, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/__init__.py`, **Entity**: `_powerSGD_comm_hook_wrapper`, **Line**: 27, **Description**: First line should end with a period (not ',')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/__init__.py`, **Entity**: `DDPCommHookType`, **Line**: 40, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/__init__.py`, **Entity**: `DDPCommHookType`, **Line**: 40, **Description**: First line should end with a period (not '`')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/__init__.py`, **Entity**: `register_ddp_comm_hook`, **Line**: 91, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/__init__.py`, **Entity**: `register_ddp_comm_hook`, **Line**: 91, **Description**: First line should end with a period (not '`')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/__init__.py`, **Entity**: `register_ddp_comm_hook`, **Line**: 91, **Description**: First line should be in imperative mood (perhaps 'Register', not 'Registers')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/mixed_precision_hooks.py`, **Entity**: `_AllreduceUpcastHookState`, **Line**: 11, **Description**: 1 blank line required after class docstring (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/mixed_precision_hooks.py`, **Entity**: `_AllreduceUpcastHookState`, **Line**: 11, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/mixed_precision_hooks.py`, **Entity**: `_reducer_allreduce_and_upcast_hook`, **Line**: 24, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/mixed_precision_hooks.py`, **Entity**: `_reducer_allreduce_and_upcast_hook`, **Line**: 24, **Description**: First line should end with a period (not 'n')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/mixed_precision_hooks.py`, **Entity**: `_reducer_allreduce_and_upcast_hook`, **Line**: 24, **Description**: First line should be in imperative mood (perhaps 'Perform', not 'Performs')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/optimizer_overlap_hooks.py`, **Entity**: `_OptimizerHookState`, **Line**: 14, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/optimizer_overlap_hooks.py`, **Entity**: `_apply_optim_in_backward_hook`, **Line**: 47, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/optimizer_overlap_hooks.py`, **Entity**: `_apply_optim_in_backward_hook`, **Line**: 47, **Description**: First line should end with a period (not 'p')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/optimizer_overlap_hooks.py`, **Entity**: `_hook_then_optimizer`, **Line**: 126, **Description**: One-line docstring should fit on one line with quotes (found 3)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/optimizer_overlap_hooks.py`, **Entity**: `_hook_then_optimizer`, **Line**: 126, **Description**: First line should be in imperative mood (perhaps 'Run', not 'Runs')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/post_localSGD_hook.py`, **Entity**: `PostLocalSGDState`, **Line**: 12, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/post_localSGD_hook.py`, **Entity**: `PostLocalSGDState`, **Line**: 12, **Description**: First line should end with a period (not ',')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/post_localSGD_hook.py`, **Entity**: `post_localSGD_hook`, **Line**: 68, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/post_localSGD_hook.py`, **Entity**: `post_localSGD_hook`, **Line**: 68, **Description**: First line should end with a period (not ',')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/post_localSGD_hook.py`, **Entity**: `post_localSGD_hook`, **Line**: 68, **Description**: First line should be in imperative mood; try rephrasing (found 'This')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/powerSGD_hook.py`, **Entity**: `_orthogonalize`, **Line**: 20, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/powerSGD_hook.py`, **Entity**: `_orthogonalize_gram_schmidt`, **Line**: 41, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/powerSGD_hook.py`, **Entity**: `_orthogonalize_gram_schmidt`, **Line**: 41, **Description**: First line should be in imperative mood (perhaps 'Apply', not 'Applies')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/powerSGD_hook.py`, **Entity**: `_should_compress`, **Line**: 75, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/powerSGD_hook.py`, **Entity**: `_should_compress`, **Line**: 75, **Description**: First line should end with a period (not ',')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/powerSGD_hook.py`, **Entity**: `_should_compress`, **Line**: 75, **Description**: First line should be in imperative mood (perhaps 'Return', not 'Returns')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/powerSGD_hook.py`, **Entity**: `_report_compression_stats`, **Line**: 100, **Description**: One-line docstring should fit on one line with quotes (found 3)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/powerSGD_hook.py`, **Entity**: `PowerSGDState`, **Line**: 116, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/powerSGD_hook.py`, **Entity**: `__getstate__`, **Line**: 268, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/powerSGD_hook.py`, **Entity**: `__getstate__`, **Line**: 268, **Description**: First line should be in imperative mood (perhaps 'Return', not 'Returns')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/powerSGD_hook.py`, **Entity**: `__setstate__`, **Line**: 282, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/powerSGD_hook.py`, **Entity**: `__setstate__`, **Line**: 282, **Description**: First line should be in imperative mood (perhaps 'Take', not 'Takes')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/powerSGD_hook.py`, **Entity**: `compression_stats`, **Line**: 306, **Description**: First line should end with a period (not '
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/powerSGD_hook.py`, **Entity**: `compression_stats`, **Line**: 306, **Description**: First line should be in imperative mood (perhaps 'Return', not 'Returns')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/powerSGD_hook.py`, **Entity**: `powerSGD_hook`, **Line**: 330, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/powerSGD_hook.py`, **Entity**: `powerSGD_hook`, **Line**: 330, **Description**: First line should end with a period (not 'n')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/powerSGD_hook.py`, **Entity**: `powerSGD_hook`, **Line**: 330, **Description**: First line should be in imperative mood; try rephrasing (found 'This')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/powerSGD_hook.py`, **Entity**: `batched_powerSGD_hook`, **Line**: 638, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/powerSGD_hook.py`, **Entity**: `batched_powerSGD_hook`, **Line**: 638, **Description**: First line should end with a period (not 'n')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/powerSGD_hook.py`, **Entity**: `batched_powerSGD_hook`, **Line**: 638, **Description**: First line should be in imperative mood; try rephrasing (found 'This')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/powerSGD_hook.py`, **Entity**: `create_low_rank_tensor`, **Line**: 753, **Description**: Use """triple double quotes""" (found "-quotes)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/powerSGD_hook.py`, **Entity**: `create_low_rank_tensor`, **Line**: 753, **Description**: First line should be in imperative mood (perhaps 'Return', not 'Returns')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/quantization_hooks.py`, **Entity**: `quantization_pertensor_hook`, **Line**: 48, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/quantization_hooks.py`, **Entity**: `quantization_pertensor_hook`, **Line**: 48, **Description**: First line should end with a period (not '`')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/quantization_hooks.py`, **Entity**: `quantization_pertensor_hook`, **Line**: 48, **Description**: First line should be in imperative mood (perhaps 'Apply', not 'Applies')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/quantization_hooks.py`, **Entity**: `quantization_perchannel_hook`, **Line**: 122, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/quantization_hooks.py`, **Entity**: `quantization_perchannel_hook`, **Line**: 122, **Description**: First line should end with a period (not '`')
- **File**: `torch/distributed/algorithms/ddp_comm_hooks/quantization_hooks.py`, **Entity**: `quantization_perchannel_hook`, **Line**: 122, **Description**: First line should be in imperative mood (perhaps 'Apply', not 'Applies')
- **File**: `torch/distributed/algorithms/model_averaging/averagers.py`, **Entity**: `average_parameters`, **Line**: 106, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/model_averaging/averagers.py`, **Entity**: `average_parameters`, **Line**: 106, **Description**: First line should end with a period (not '`')
- **File**: `torch/distributed/algorithms/model_averaging/utils.py`, **Entity**: `average_parameters`, **Line**: 17, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/model_averaging/utils.py`, **Entity**: `get_params_to_average`, **Line**: 45, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/model_averaging/utils.py`, **Entity**: `get_params_to_average`, **Line**: 45, **Description**: First line should be in imperative mood (perhaps 'Return', not 'Returns')
- **File**: `torch/distributed/algorithms/model_averaging/utils.py`, **Entity**: `average_parameters_or_parameter_groups`, **Line**: 68, **Description**: One-line docstring should fit on one line with quotes (found 3)
- **File**: `torch/distributed/algorithms/model_averaging/hierarchical_model_averager.py`, **Entity**: `HierarchicalModelAverager`, **Line**: 16, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/model_averaging/hierarchical_model_averager.py`, **Entity**: `_find_process_group`, **Line**: 137, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/model_averaging/hierarchical_model_averager.py`, **Entity**: `_find_process_group`, **Line**: 137, **Description**: First line should end with a period (not ',')
- **File**: `torch/distributed/algorithms/model_averaging/hierarchical_model_averager.py`, **Entity**: `_find_process_group`, **Line**: 137, **Description**: First line should be in imperative mood (perhaps 'Return', not 'Returns')
- **File**: `torch/distributed/algorithms/model_averaging/hierarchical_model_averager.py`, **Entity**: `average_parameters`, **Line**: 151, **Description**: 1 blank line required between summary line and description (found 0)
- **File**: `torch/distributed/algorithms/model_averaging/hierarchical_model_averager.py`, **Entity**: `average_parameters`, **Line**: 151, **Description**: First line should end with a period (not '`')

cc @carljparker