mirror of
https://github.com/salesforce/BLIP.git
synced 2026-01-26 15:19:44 +00:00
update demo
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
"cells": [
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"id": "bb2e6f60",
|
||||
"id": "2b949f9f",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"# BLIP: Inference Demo"
|
||||
@@ -93,7 +93,7 @@
|
||||
"\n",
|
||||
"model_url = 'https://storage.googleapis.com/sfr-vision-language-research/BLIP/models/model*_base_caption.pth'\n",
|
||||
" \n",
|
||||
"model = blip_decoder(pretrained=model_url, image_size=384, vit='base')\n",
|
||||
"model = blip_decoder(pretrained=model_url, image_size=384, vit='base', med_config='BLIP/configs/med_config.json')\n",
|
||||
"model.eval()\n",
|
||||
"model = model.to(device)\n",
|
||||
"\n",
|
||||
@@ -139,7 +139,7 @@
|
||||
"\n",
|
||||
"model_url = 'https://storage.googleapis.com/sfr-vision-language-research/BLIP/models/model*_vqa.pth'\n",
|
||||
" \n",
|
||||
"model = blip_vqa(pretrained=model_url, image_size=480, vit='base')\n",
|
||||
"model = blip_vqa(pretrained=model_url, image_size=480, vit='base', med_config='BLIP/configs/med_config.json')\n",
|
||||
"model.eval()\n",
|
||||
"model = model.to(device)\n",
|
||||
"\n",
|
||||
|
||||
Reference in New Issue
Block a user