Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions docs/docs/integrations/tools/google_imagen.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"- [VertexAIImageEditorChat](#image-editing) : Edit an entire uploaded or generated image with a text prompt.\n",
"- [VertexAIImageCaptioning](#image-captioning) : Get text descriptions of images with visual captioning.\n",
"- [VertexAIVisualQnAChat](#visual-question-answering-vqa) : Get answers to a question about an image with Visual Question Answering (VQA).\n",
" * NOTE : Currently we support only only single-turn chat for Visual QnA (VQA)"
" * NOTE : Currently we support only single-turn chat for Visual QnA (VQA)"
]
},
{
Expand All @@ -48,11 +48,11 @@
},
{
"cell_type": "code",
"execution_count": 3,
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"# Create Image Gentation model Object\n",
"# Create Image Generation model Object\n",
"generator = VertexAIImageGeneratorChat()"
]
},
Expand Down Expand Up @@ -140,11 +140,11 @@
},
{
"cell_type": "code",
"execution_count": 11,
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"# Create Image Gentation model Object\n",
"# Create Image Generation model Object\n",
"generator = VertexAIImageGeneratorChat()\n",
"\n",
"# Provide a text input for image\n",
Expand Down Expand Up @@ -244,7 +244,7 @@
},
{
"cell_type": "code",
"execution_count": 19,
"execution_count": null,
"metadata": {},
"outputs": [
{
Expand All @@ -268,10 +268,10 @@
}
],
"source": [
"# use image egenarted in Image Generation Section\n",
"# use image generated in Image Generation Section\n",
"img_base64 = generated_image[\"image_url\"][\"url\"]\n",
"response = model.invoke(img_base64)\n",
"print(f\"Generated Cpation : {response}\")\n",
"print(f\"Generated Caption : {response}\")\n",
"\n",
"# Convert base64 string to Image\n",
"img = Image.open(\n",
Expand Down
Loading