Skip to content

Fix CP slice parallel state access#1185

Merged
yushengsu-thu merged 1 commit into
radixark:mainfrom
kaixih:kaixi/fix-cp-slice-parallel-state
May 24, 2026
Merged

Fix CP slice parallel state access#1185
yushengsu-thu merged 1 commit into
radixark:mainfrom
kaixih:kaixi/fix-cp-slice-parallel-state

Conversation

@kaixih
Copy link
Copy Markdown
Contributor

@kaixih kaixih commented May 23, 2026

Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request updates the slice_with_cp function in miles/backends/training_utils/cp_utils.py to access context parallel rank and size through a nested cp object within parallel_state rather than using direct attributes. I have no feedback to provide as there were no review comments.

Copy link
Copy Markdown
Collaborator

@yushengsu-thu yushengsu-thu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@guapisolo I also encounter the same problem. This should fix ~

Copy link
Copy Markdown
Collaborator

@guapisolo guapisolo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@yushengsu-thu yushengsu-thu enabled auto-merge (squash) May 24, 2026 04:27
@yushengsu-thu yushengsu-thu merged commit d2e0b35 into radixark:main May 24, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants