Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion deepspeed/runtime/zero/constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@
ZERO_OPTIMIZATION_OFFLOAD_OPTIMIZER_DEFAULT = None

ZERO_OPTIMIZATION_SUB_GROUP_SIZE = 'sub_group_size'
ZERO_OPTIMIZATION_SUB_GROUP_SIZE_DEFAULT = 1000000000000
ZERO_OPTIMIZATION_SUB_GROUP_SIZE_DEFAULT = 1000000000

#maximum number of parameters per GPU before releasing them
ZERO_OPTIMIZATION_MAX_LIVE_PARAMETERS = 'stage3_max_live_parameters'
Expand Down
5 changes: 4 additions & 1 deletion deepspeed/runtime/zero/stage3.py
Original file line number Diff line number Diff line change
Expand Up @@ -852,7 +852,10 @@ def __init__(self,
count = count + 1

#Largest partitioned param
largest_partitioned_param_numel = max(self.fp16_partitioned_groups_flat_numel)
largest_partitioned_param_numel = max([
max([tensor.numel() for tensor in fp16_partitioned_group])
for fp16_partitioned_group in self.fp16_partitioned_groups
])
print_rank_0(
f'Largest partitioned param numel = {largest_partitioned_param_numel}',
force=True)
Expand Down