Skip to content
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

Hardware Auto-Setup for Examples #22319

Merged
merged 8 commits into from
Mar 27, 2023

Conversation

dongreenberg
Copy link
Contributor

@dongreenberg dongreenberg commented Mar 22, 2023

What does this PR do?

Discussed with @sgugger and @LysandreJik . This PR introduces auto-setup functionality for tutorials and examples (we are sending a parallel PR to accelerate, and maybe Diffusers and Spaces shortly). This allows users to run transformers code, tutorials, and scripts on self-hosted hardware (either their own instance or a cloud instances) including on-demand allocation of the hardware itself on AWS, GCP, Azure, or Lambda Labs, and installation of dependencies. This introduces a similar level of turnkey usage and reproducibility that users only typically expect in Colab, but for any type of hardware on any cloud (we've tested on Paperspace and Coreweave as well, allocating the instance in their UI and then plugging in the IP as a static cluster). Note that Runhouse OSS is facilitating the setup (via SkyPilot) and rpc, but users don't don't need to create a Runhouse account or anything like that, this is strictly inside their own cloud accounts with their own credentials (or using their IP and ssh creds without a cloud account).

Before submitting

@HuggingFaceDocBuilderDev
Copy link

HuggingFaceDocBuilderDev commented Mar 22, 2023

The documentation is not available anymore as the PR was closed or merged.

Copy link
Collaborator

@sgugger sgugger left a comment

Choose a reason for hiding this comment

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

Thanks a lot for your PR. While we're super happy to showcase RunHouse examples, I feel having one page in the doc is maybe a step too far at this stage. Could we focus first on:

  • having one example as you did
  • say a bit more clearly in the README that RunHouse is one way to run the examples remotely (and there might be others)
  • make launch_auto_hardware.mdx a notebook you host on your side and link to it from the examples/README.md

What so you think?

@dongreenberg
Copy link
Contributor Author

Definitely, that makes sense, and thanks for the fast review! Updated per your suggestions.

@dongreenberg dongreenberg changed the title Hardware Auto-Setup for Tutorials and Examples Hardware Auto-Setup for Examples Mar 24, 2023
@sgugger
Copy link
Collaborator

sgugger commented Mar 27, 2023

Thanks for iterating! There is just the issue of the tests that are not running now. It seems there is an issue with your CircleCI permissions. Could you try refreshing your permissions as shown here?

@dongreenberg
Copy link
Contributor Author

Oh sorry! I think I've granted it access. Do I need to trigger anything on my side?

@sgugger
Copy link
Collaborator

sgugger commented Mar 27, 2023

Probably an empty commit to re-trigger the CI.

@sgugger
Copy link
Collaborator

sgugger commented Mar 27, 2023

Ok, so it looks like we just need a quick make style to fix the formatting on the added examples and we should be good to go.

@dongreenberg
Copy link
Contributor Author

Oops, thought I already ran via make fixup. Pushed!

@sgugger
Copy link
Collaborator

sgugger commented Mar 27, 2023

Ok, last failures are fixed on main so merging. Thanks!

@sgugger sgugger merged commit f02e3a2 into huggingface:main Mar 27, 2023
@dongreenberg
Copy link
Contributor Author

Thank you, Sylvain!!

raghavanone pushed a commit to raghavanone/transformers that referenced this pull request Apr 5, 2023
* Add initial remote hardware auto-setup docs

* Fix a few typos and clarify some language

* Add missing dependency

* Update self-hosted launch script with Sylvain's comments.

* Formatting.

* Trigger CI

* Style
novice03 pushed a commit to novice03/transformers that referenced this pull request Jun 23, 2023
* Add initial remote hardware auto-setup docs

* Fix a few typos and clarify some language

* Add missing dependency

* Update self-hosted launch script with Sylvain's comments.

* Formatting.

* Trigger CI

* Style
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.

3 participants