Skip to content

Add auto-reload support to CodeSyncManager #568

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from

Conversation

andrewjcg
Copy link
Contributor

Summary:
Update the CodeSyncManager actor to call AutoReloadActor
when requested, to trigger hot-reloading of Python code after
code sync completes.

In this setup, only a single CodeSyncManager on an e.g. host
will perform a code sync operation, and then will cast to all ranks
that share the host (e.g. gpu ranks) to trigger all the reloads.

Differential Revision: D78358200

@meta-cla meta-cla bot added the CLA Signed This label is managed by the Meta Open Source bot. label Jul 17, 2025
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D78358200

andrewjcg added a commit to andrewjcg/monarch that referenced this pull request Jul 17, 2025
Summary:
Pull Request resolved: pytorch-labs#568

Update the `CodeSyncManager` actor to call `AutoReloadActor`
when requested, to trigger hot-reloading of Python code after
code sync completes.

In this setup, only a single `CodeSyncManager` on an e.g. host
will perform a code sync operation, and then will cast to all ranks
that share the host (e.g. gpu ranks) to trigger all the reloads.

Differential Revision: D78358200
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D78358200

1 similar comment
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D78358200

andrewjcg added a commit to andrewjcg/monarch that referenced this pull request Jul 17, 2025
Summary:
Pull Request resolved: pytorch-labs#568

Update the `CodeSyncManager` actor to call `AutoReloadActor`
when requested, to trigger hot-reloading of Python code after
code sync completes.

In this setup, only a single `CodeSyncManager` on an e.g. host
will perform a code sync operation, and then will cast to all ranks
that share the host (e.g. gpu ranks) to trigger all the reloads.

Differential Revision: D78358200
@andrewjcg andrewjcg force-pushed the export-D78358200 branch 2 times, most recently from a1667b6 to a3f6a97 Compare July 18, 2025 17:35
andrewjcg added a commit to andrewjcg/monarch that referenced this pull request Jul 18, 2025
Summary:

Update the `CodeSyncManager` actor to call `AutoReloadActor`
when requested, to trigger hot-reloading of Python code after
code sync completes.

In this setup, only a single `CodeSyncManager` on an e.g. host
will perform a code sync operation, and then will cast to all ranks
that share the host (e.g. gpu ranks) to trigger all the reloads.

Differential Revision: D78358200
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D78358200

andrewjcg added a commit to andrewjcg/monarch that referenced this pull request Jul 19, 2025
Summary:

Update the `CodeSyncManager` actor to call `AutoReloadActor`
when requested, to trigger hot-reloading of Python code after
code sync completes.

In this setup, only a single `CodeSyncManager` on an e.g. host
will perform a code sync operation, and then will cast to all ranks
that share the host (e.g. gpu ranks) to trigger all the reloads.

Differential Revision: D78358200
andrewjcg added a commit to andrewjcg/monarch that referenced this pull request Jul 19, 2025
Summary:

Update the `CodeSyncManager` actor to call `AutoReloadActor`
when requested, to trigger hot-reloading of Python code after
code sync completes.

In this setup, only a single `CodeSyncManager` on an e.g. host
will perform a code sync operation, and then will cast to all ranks
that share the host (e.g. gpu ranks) to trigger all the reloads.

Differential Revision: D78358200
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D78358200

andrewjcg added a commit to andrewjcg/monarch that referenced this pull request Jul 19, 2025
Summary:
Pull Request resolved: pytorch-labs#568

Update the `CodeSyncManager` actor to call `AutoReloadActor`
when requested, to trigger hot-reloading of Python code after
code sync completes.

In this setup, only a single `CodeSyncManager` on an e.g. host
will perform a code sync operation, and then will cast to all ranks
that share the host (e.g. gpu ranks) to trigger all the reloads.

Differential Revision: D78358200
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D78358200

andrewjcg added a commit to andrewjcg/monarch that referenced this pull request Jul 19, 2025
Summary:
Pull Request resolved: pytorch-labs#568

Update the `CodeSyncManager` actor to call `AutoReloadActor`
when requested, to trigger hot-reloading of Python code after
code sync completes.

In this setup, only a single `CodeSyncManager` on an e.g. host
will perform a code sync operation, and then will cast to all ranks
that share the host (e.g. gpu ranks) to trigger all the reloads.

Differential Revision: D78358200
@andrewjcg andrewjcg force-pushed the export-D78358200 branch 2 times, most recently from 78e4181 to 753ee3f Compare July 21, 2025 14:18
andrewjcg added a commit to andrewjcg/monarch that referenced this pull request Jul 21, 2025
Summary:

Update the `CodeSyncManager` actor to call `AutoReloadActor`
when requested, to trigger hot-reloading of Python code after
code sync completes.

In this setup, only a single `CodeSyncManager` on an e.g. host
will perform a code sync operation, and then will cast to all ranks
that share the host (e.g. gpu ranks) to trigger all the reloads.

Reviewed By: highker

Differential Revision: D78358200
andrewjcg added a commit to andrewjcg/monarch that referenced this pull request Jul 21, 2025
Summary:

Update the `CodeSyncManager` actor to call `AutoReloadActor`
when requested, to trigger hot-reloading of Python code after
code sync completes.

In this setup, only a single `CodeSyncManager` on an e.g. host
will perform a code sync operation, and then will cast to all ranks
that share the host (e.g. gpu ranks) to trigger all the reloads.

Reviewed By: highker

Differential Revision: D78358200
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D78358200

andrewjcg added a commit to andrewjcg/monarch that referenced this pull request Jul 21, 2025
Summary:
Pull Request resolved: pytorch-labs#568

Update the `CodeSyncManager` actor to call `AutoReloadActor`
when requested, to trigger hot-reloading of Python code after
code sync completes.

In this setup, only a single `CodeSyncManager` on an e.g. host
will perform a code sync operation, and then will cast to all ranks
that share the host (e.g. gpu ranks) to trigger all the reloads.

Reviewed By: highker

Differential Revision: D78358200
Summary:
Pull Request resolved: pytorch-labs#568

Update the `CodeSyncManager` actor to call `AutoReloadActor`
when requested, to trigger hot-reloading of Python code after
code sync completes.

In this setup, only a single `CodeSyncManager` on an e.g. host
will perform a code sync operation, and then will cast to all ranks
that share the host (e.g. gpu ranks) to trigger all the reloads.

Reviewed By: highker

Differential Revision: D78358200
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D78358200

@facebook-github-bot
Copy link
Contributor

This pull request has been merged in 4cf5147.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Meta Open Source bot. fb-exported Merged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants