This document contains a list of Imagen on Vertex AI Jupyter Notebook tutorials and articles with code samples.
There are many environments in which you can host Jupyter Notebooks. You can:
- Download them from GitHub and run them on your local machine
- Download them from GitHub and run them on a Jupyter or JupyterLab server in your local network
Run them in the cloud using a service like Colaboratory (Colab) or Vertex AI Workbench.
Colab
Running a Jupyter Notebook in Colab is an easy way to get started quickly.
To open a notebook tutorial in Colab, click the Colab link in the notebook list. Colab creates a VM instance with all needed dependencies, launches the Colab environment, and loads the notebook.
Vertex AI Workbench
You can also run the notebook using user-managed notebooks. When you create a user-managed notebooks instance with Vertex AI Workbench, you have full control over the hosting VM. You can specify the configuration and environment of the hosting VM.
To open a notebook tutorial in a Vertex AI Workbench instance:
- Click the Vertex AI Workbench link in the notebook list. The link opens the Vertex AI Workbench console.
- In the Deploy to notebook screen, type a name for your new Vertex AI Workbench instance and click Create.
- In the Ready to open notebook dialog that appears after the instance starts, click Open.
- On the Confirm deployment to notebook server page, select Confirm.
- Before running the notebook, select Kernel > Restart Kernel and Clear all Outputs.
List of notebooks
Features | Description | Open in |
---|---|---|
Image generation (Imagen 2) |
Image Generation with Imagen on Vertex AI.
In this notebook, you explore the image generation features of Imagen using the Vertex AI SDK for Python. Learn more about Imagen's image generation feature. Tutorial steps
|
Colab
GitHub Vertex AI Workbench |
Image generation (Imagen 2) Text generation (Gemini 1.0 Pro) Output text formatting (Gemini 1.0 Pro) |
Create high quality visual assets with Imagen and Gemini 1.0 Pro.
In this notebook, you create high quality visual assets for a restaurant menu using Imagen and Gemini 1.0 Pro. Learn more about image generation and multimodal models. Tutorial steps
|
Colab
GitHub Vertex AI Workbench |
Image editing (Imagen 2) |
Create high quality visual assets with Imagen 2 edit using automatically generated mask areas.
In this notebook, you will be exploring the image editing features of Imagen using the Vertex AI SDK for Python. Tutorial steps
|
Colab
GitHub Vertex AI Workbench |
Image descriptions / visual captioning (Imagen) |
Visual captioning with Imagen on Vertex AI.
In this notebook, you will learn how to use the Vertex AI SDK for Python to generate visual captions for an image. Learn more about Imagen's image captioning feature. Tutorial steps
|
Colab
GitHub Vertex AI Workbench |
Visual Question Answering (VQA) (Imagen) |
Visual Question Answering (VQA) with Imagen on Vertex AI.
In this notebook, you will learn how to use the Vertex AI SDK for Python to generate answers for questions you ask about an image. Learn more about Imagen's Visual Question Answering (VQA) feature. Tutorial steps
|
Colab
GitHub Vertex AI Workbench |
List of articles with samples
Features | Description | Links |
---|---|---|
Image editing (Imagen) |
Background change with Imagen on Vertex AI: A step-by-step guide.
This article shows how to do mask-based editing using the Vertex AI SDK for Python. Changing the background involves the following steps:
|
Article link
GitHub |
Image generation (Imagen) Text generation (PaLM 2 for Text) |
Google Imagen (through Google Cloud Vertex AI Studio) as fashion design assistant.
In this article, we will explore how generative AI can assist fashion designers in
generating new ideas and designs using Google's suite of generative models for text
and image generation. This article shows you how to use PaLM 2 for Text's
Learn more about Imagen's image generation feature and PaLM 2 for Text's text generation feature. |
Article link
|
Image generation (Imagen 2) Image editing (Imagen) |
Image generation with Imagen and LangChain4j (Java).
In this article, we will explore how you can generate and edit images with Imagen in LangChain4j. Learn more about Imagen's image generation and image editing features. |
Article link
|