MountaintopLotus / braintrust

A Dockerized platform for running Stable Diffusion, on AWS (for now)
Apache License 2.0
1 stars 2 forks source link

SageMaker #27

Open JohnTigue opened 1 year ago

JohnTigue commented 1 year ago

See also #50.

Your own Stable Diffusion endpoint with AWS SageMaker

JohnTigue commented 1 year ago

Expensive Cat pictures with Stable Diffusion on AWS SageMaker in CDK

JohnTigue commented 1 year ago

Keep finger crossed. Awesome contributors of Automatic1111 WebUI are on the way to make Dreambooth on 8-10 GB VRam possible:

AWS Sagemaker Studio is getting a free tier called Lab specifically for deep learning training. 8 hours of T4 per day (2x 4 hours), that's about 120 USD in compute monthly (4 USD per day) for free. It uses a Jupyter interface like Google Colab.

JohnTigue commented 1 year ago

Here's a guy who deploys A1111 to EC2 and then in his todo notes says, ~"migrate to SageMaker": https://github.com/ManyHands/hypnowerk/issues/5#issuecomment-1381199618.

SageMaker? Sure good idea: could run the Colab notebooks privately on good GPUs. But A1111 in SageMaker? Do tell… go on…

JohnTigue commented 1 year ago

Running the webui on SageMaker Studio Lab #4820: "Jupyter notebook for running stable-diffusion-webui on (free) SageMaker Studio Lab:"

JohnTigue commented 1 year ago

Here's more A1111 on SageMaker.

JohnTigue commented 1 year ago

This is nice work Stable Diffusion WebUI (AUTOMATIC1111) for SageMaker Studio Lab:

This notebook will install and run the stable-diffusion-webui repository by AUTOMATIC1111 on SageMaker Studio Lab

With the default model you can run textual inversion training, hypernetwork training and image generation, but no native training

JohnTigue commented 1 year ago

We'll want to have Docker images with SD on them, made to work with SageMaker: Using Docker containers with SageMaker. I bet it would be pretty easy to get Invoke and JupyterLab running on the same SageMaker instance.

JohnTigue commented 1 year ago

We can use our foo@manyhands.io accounts to sign into SageMaker, see Identity and Access Management for Amazon SageMaker:

You can sign in to AWS as a federated identity by using credentials provided through an identity source. AWS IAM Identity Center (successor to AWS Single Sign-On) (IAM Identity Center) users, your company's single sign-on authentication, and your Google or Facebook credentials are examples of federated identities. When you sign in as a federated identity, your administrator previously set up identity federation using IAM roles. When you access AWS by using federation, you are indirectly assuming a role.

JohnTigue commented 1 year ago

They seem to have SD enabled instances ready to roll as of November: Generate images from text with the stable diffusion model on Amazon SageMaker JumpStart. Note that this does not include an SD webUI such as Auto1111 or InvokeAI.

JohnTigue commented 1 year ago

Train and deploy a custom GPU-supported ML model on Amazon SageMaker

JohnTigue commented 1 year ago

SD txt2img on CLI inside SageMaker:

JohnTigue commented 1 year ago

SIWG in SageMaker: Identity and Access Management for Amazon SageMaker:

You can sign in to AWS as a federated identity by using credentials provided through an identity source. AWS IAM Identity Center (successor to AWS Single Sign-On) (IAM Identity Center) users, your company's single sign-on authentication, and your Google or Facebook credentials are examples of federated identities.

JohnTigue commented 1 year ago

Generate images from text with the stable diffusion model on Amazon SageMaker JumpStart

JohnTigue commented 1 year ago