Get the total number of parameters in the model, including all the transformer layers and the embedding layer. Returns: int: the total number of parameters in the model
(self)
| 337 | self.get_num_params_last_layernorm()) |
| 338 | |
| 339 | def get_num_active_params_total(self) -> int: |
| 340 | """Get the total number of parameters in the model, including all the |
| 341 | transformer layers and the embedding layer. |
| 342 | |
| 343 | Returns: |
| 344 | int: the total number of parameters in the model |
| 345 | """ |
| 346 | return (self.model_config.num_layers * |
| 347 | self.get_num_active_params_per_layer() + |
| 348 | self.get_num_params_embedding() + |
| 349 | self.get_num_params_last_layernorm()) |
| 350 | |
| 351 | def get_weight_memory_per_layer( |
| 352 | self, |
no test coverage detected