Skip to content

[DeviceMesh] Remove private _set_mesh_dim_group_options API#164750

Closed
fduwjj wants to merge 3 commits intogh/fduwjj/219/basefrom
gh/fduwjj/219/head
Closed

[DeviceMesh] Remove private _set_mesh_dim_group_options API#164750
fduwjj wants to merge 3 commits intogh/fduwjj/219/basefrom
gh/fduwjj/219/head

Conversation

@fduwjj
Copy link
Contributor

@fduwjj fduwjj commented Oct 6, 2025

Stack from ghstack (oldest at bottom):

We allow passing in PG option via #159371 and we did a clean up of Meta internal usage of _set_mesh_dim_group_options, since this a private API, we don't have any bc guarantee, we want to directly remove so that people use the new behavior from now on.

Also since we now allow passing pg in both DeviceMesh constructor and flatten API, so that we also want to get rid of the global pg option override variable.

cc @H-Huang @awgu @wanchaol @fegin @wz337 @wconstab @d4l3k @pragupta @msaroufim @dcci

@pytorch-bot
Copy link

pytorch-bot bot commented Oct 6, 2025

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/164750

Note: Links to docs will display an error until the docs builds have been completed.

✅ No Failures

As of commit 58cbd49 with merge base 322091d (image):
💚 Looks good so far! There are no failures yet. 💚

This comment was automatically generated by Dr. CI and updates every 15 minutes.

fduwjj added a commit that referenced this pull request Oct 6, 2025
ghstack-source-id: 8c9265e
Pull Request resolved: #164750
@pytorch-bot pytorch-bot bot added the oncall: distributed Add this issue/PR to distributed oncall triage queue label Oct 6, 2025
@fduwjj fduwjj requested review from ezyang, fegin and lw October 6, 2025 17:24
@fduwjj fduwjj changed the title [DeviceMesh] Remove private set_pg_option API [DeviceMesh] Remove private _set_mesh_dim_group_options API Oct 6, 2025
Copy link
Contributor

@lw lw left a comment

Choose a reason for hiding this comment

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

Awesome! Thanks!

@fduwjj fduwjj added the ciflow/trunk Trigger trunk jobs on your pull request label Oct 6, 2025
We allow passing in PG option via #159371 and we did a clean up of Meta internal usage of `_set_mesh_dim_group_options`, since this a private API, we don't have any bc guarantee, we want to directly remove so that people use the new behavior from now on.

Also since we now allow passing pg in both DeviceMesh constructor and flatten API, so that we also want to get rid of the global pg option override variable.

cc H-Huang awgu wanchaol fegin wz337 wconstab d4l3k pragupta msaroufim dcci

[ghstack-poisoned]
fduwjj added a commit that referenced this pull request Oct 8, 2025
ghstack-source-id: 51034f1
Pull Request resolved: #164750
We allow passing in PG option via #159371 and we did a clean up of Meta internal usage of `_set_mesh_dim_group_options`, since this a private API, we don't have any bc guarantee, we want to directly remove so that people use the new behavior from now on.

Also since we now allow passing pg in both DeviceMesh constructor and flatten API, so that we also want to get rid of the global pg option override variable.

cc H-Huang awgu wanchaol fegin wz337 wconstab d4l3k pragupta msaroufim dcci

[ghstack-poisoned]
fduwjj added a commit that referenced this pull request Oct 8, 2025
ghstack-source-id: 93d66a2
Pull Request resolved: #164750
@fduwjj
Copy link
Contributor Author

fduwjj commented Oct 8, 2025

@pytorchbot merge

@pytorchmergebot
Copy link
Collaborator

Merge started

Your change will be merged once all checks pass (ETA 0-4 Hours).

Learn more about merging in the wiki.

Questions? Feedback? Please reach out to the PyTorch DevX Team

Advanced Debugging
Check the merge workflow status
here

pytorchmergebot pushed a commit that referenced this pull request Oct 8, 2025
…cess API (#164954)

This is mostly mechanical change which make device mesh members all private and use a public property API instead. This is not a BC breaking change since the new API still guarantee BC.

Pull Request resolved: #164954
Approved by: https://github.com/fegin
ghstack dependencies: #164750
pytorchmergebot pushed a commit that referenced this pull request Oct 9, 2025
…nd types for _get_slice_mesh_layout (#164993)

As title, we want to add a deprecate warning for slicing flattened dim from root mesh. Also cosmetic changes for adding types for `_get_slice_mesh_layout`.

Pull Request resolved: #164993
Approved by: https://github.com/fegin
ghstack dependencies: #164750, #164954
Chao1Han pushed a commit to Chao1Han/pytorch that referenced this pull request Oct 21, 2025
…164750)

We allow passing in PG option via pytorch#159371 and we did a clean up of Meta internal usage of `_set_mesh_dim_group_options`, since this a private API, we don't have any bc guarantee, we want to directly remove so that people use the new behavior from now on.

Also since we now allow passing pg in both DeviceMesh constructor and flatten API, so that we also want to get rid of the global pg option override variable.

Pull Request resolved: pytorch#164750
Approved by: https://github.com/lw, https://github.com/fegin
Chao1Han pushed a commit to Chao1Han/pytorch that referenced this pull request Oct 21, 2025
…cess API (pytorch#164954)

This is mostly mechanical change which make device mesh members all private and use a public property API instead. This is not a BC breaking change since the new API still guarantee BC.

Pull Request resolved: pytorch#164954
Approved by: https://github.com/fegin
ghstack dependencies: pytorch#164750
Chao1Han pushed a commit to Chao1Han/pytorch that referenced this pull request Oct 21, 2025
…nd types for _get_slice_mesh_layout (pytorch#164993)

As title, we want to add a deprecate warning for slicing flattened dim from root mesh. Also cosmetic changes for adding types for `_get_slice_mesh_layout`.

Pull Request resolved: pytorch#164993
Approved by: https://github.com/fegin
ghstack dependencies: pytorch#164750, pytorch#164954
@github-actions github-actions bot deleted the gh/fduwjj/219/head branch November 8, 2025 02:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ciflow/trunk Trigger trunk jobs on your pull request Merged oncall: distributed Add this issue/PR to distributed oncall triage queue release notes: DeviceMesh

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants