Skip to content

Commit

Permalink
EP: add expert_* to app_state in init_model_parallel.
Browse files Browse the repository at this point in the history
Signed-off-by: Alexandros Koumparoulis <[email protected]>
  • Loading branch information
akoumpa committed Jan 26, 2024
1 parent 38dee6c commit 34fb998
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion nemo/collections/nlp/parts/nlp_overrides.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,8 @@ def init_model_parallel(sharp: bool, nccl_communicator_config_path: str = None)
assert app_state.tensor_model_parallel_rank == parallel_state.get_tensor_model_parallel_rank()
assert app_state.pipeline_model_parallel_rank == parallel_state.get_pipeline_model_parallel_rank()

# TODO(akoumparouli): expert parallelism
app_state.expert_model_parallel_rank = parallel_state.get_expert_model_parallel_rank()
app_state.expert_model_parallel_size = parallel_state.get_expert_model_parallel_world_size()
app_state.tensor_model_parallel_group = parallel_state.get_tensor_model_parallel_group()
app_state.data_parallel_group = parallel_state.get_data_parallel_group()
app_state.data_parallel_rank = parallel_state.get_data_parallel_rank()
Expand Down

0 comments on commit 34fb998

Please sign in to comment.