Unverified Commit c77b3b19 authored by github-actions[bot]'s avatar github-actions[bot] Committed by GitHub
Browse files

[format] applied code formatting on changed files in pull request 4152 (#4157)


Co-authored-by: default avatargithub-actions <github-actions@github.com>
parent f447ca18
...@@ -503,4 +503,4 @@ class DeviceMesh: ...@@ -503,4 +503,4 @@ class DeviceMesh:
num_devices = self.logical_mesh_id.shape[mesh_dim] num_devices = self.logical_mesh_id.shape[mesh_dim]
penalty_factor = num_devices / 2.0 penalty_factor = num_devices / 2.0
return (self.mesh_alpha[mesh_dim] + self.mesh_beta[mesh_dim] * return (self.mesh_alpha[mesh_dim] + self.mesh_beta[mesh_dim] *
(num_devices - 1) / num_devices / num_devices * num_bytes * penalty_factor + 0.001) (num_devices - 1) / num_devices / num_devices * num_bytes * penalty_factor + 0.001)
\ No newline at end of file
...@@ -287,4 +287,4 @@ def reduce_forward(input_, process_group): ...@@ -287,4 +287,4 @@ def reduce_forward(input_, process_group):
def reduce_backward(input_, process_group): def reduce_backward(input_, process_group):
return _ReduceBackward.apply(input_, process_group) return _ReduceBackward.apply(input_, process_group)
\ No newline at end of file
...@@ -80,7 +80,7 @@ _POLICY_LIST = { ...@@ -80,7 +80,7 @@ _POLICY_LIST = {
PolicyLocation(file_name="opt", class_name="OPTForSequenceClassificationPolicy"), PolicyLocation(file_name="opt", class_name="OPTForSequenceClassificationPolicy"),
"transformers.models.opt.modeling_opt.OPTForQuestionAnswering": "transformers.models.opt.modeling_opt.OPTForQuestionAnswering":
PolicyLocation(file_name="opt", class_name="OPTForQuestionAnsweringPolicy"), PolicyLocation(file_name="opt", class_name="OPTForQuestionAnsweringPolicy"),
# Bloom # Bloom
"transformers.models.bloom.modeling_bloom.BloomModel": "transformers.models.bloom.modeling_bloom.BloomModel":
PolicyLocation(file_name="bloom", class_name="BloomModelPolicy"), PolicyLocation(file_name="bloom", class_name="BloomModelPolicy"),
......
...@@ -86,4 +86,4 @@ def test_device_mesh_from_process_group(): ...@@ -86,4 +86,4 @@ def test_device_mesh_from_process_group():
if __name__ == '__main__': if __name__ == '__main__':
test_device_mesh() test_device_mesh()
test_device_mesh_from_process_group() test_device_mesh_from_process_group()
\ No newline at end of file
...@@ -41,4 +41,4 @@ def test_layernorm(): ...@@ -41,4 +41,4 @@ def test_layernorm():
if __name__ == '__main__': if __name__ == '__main__':
test_layernorm_1d() test_layernorm_1d()
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment