Skip to content

Commit

Permalink
fixed 0 layers
Browse files Browse the repository at this point in the history
  • Loading branch information
zhenghh04 committed Feb 6, 2025
1 parent 02b31e9 commit d25d730
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion dlio_benchmark/checkpointing/base_checkpointing.py
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ def get_layer_parameters(self, layer_index):
sharding_factor = self.dp
h, l, ffn, voc = self.args.hidden_size, self.args.num_layers, self.args.ffn_hidden_size, self.args.vocab_size
if layer_index == 0 or layer_index == l + 1:
return [h * voc // sharding_factor * dtype_size] # embedding or lm_head
return [h * voc // self.tp // sharding_factor * dtype_size] # embedding or lm_head
elif layer_index == l + 2:
return [h//sharding_factor * dtype_size]
else:
Expand Down

0 comments on commit d25d730

Please sign in to comment.