visual-chatgpt
openai
GPT-4
microsoft
人工智慧
傳送門:Auto-GPT 學習筆記
更名:TaskMatrix
TaskMatrix connects ChatGPT and a series of Visual Foundation Models to enable sending and receiving images during chatting.
支援中文
Github:https://github.com/microsoft/visual-chatgpt
簡介:Visual ChatGPT是一個基於GPT-3的對話生成模型,回答基本問題ok,生成與對話相關的圖像並對其進行影像處理。例如,它可以去除圖像中的物體或將它們替換為其他物體。(基本圖片處理ok)
a gas station
a baby with a green shirt on
換成藍衣服
分析結果
Human: provide a figure named image/xxxx.png. The description is: a man in a hat and a man in a hat. This information helps you to understand this image, but you should use tools to finish following tasks, rather than directly imagine from my description. If you understand, say "Received".
AI: Received.
Human: 請問這張照片有幾個人,請用繁體中文回答,謝謝!
AI: 這張照片有兩個人,一個戴著帽子,另一個也戴著帽子。
Human: 錯誤,背景還有一個人
AI: 從照片中可以看到,有兩個戴著帽子的人,而且背景還有一個人。
Human: 所以總共三個人
AI: 從照片中可以看到,有兩個戴著帽子的人,而且背景還有一個人,所以總共三個人。, n_tokens: 63
GPT3:a piece of bread on a plate.
Human: provide a figure named image/xxxx.png. The description is: a picture of a piece of bread on a plate. This information helps you to understand this image, but you should use tools to finish following tasks, rather than directly imagine from my description. If you understand, say "Received".
AI: Received.
Human: can u tell me this meme ?
AI: The image is of a piece of bread on a plate.
Human: why is that meme funny ?
AI: The image is of a piece of bread on a plate, but it is not possible to determine why it is funny from the image.
Visual ChatGPT 是基於 OpenAI 的 GPT 模型所建立的,因此需要先申請 OpenAI API 並獲取 API key 才能使用。您可以依照以下步驟完成申請:
可前往 Python 官方網站 https://www.python.org/downloads/ 下載 Python
這裡提供 Windows、macOS 和 Linux 三種作業系統的安裝檔案。
下載後直接執行安裝程式即可完成安裝。
fork 下來檔案後建立 virtual environment
最新版本教學:Quick Start
官方給的簡易教學步驟 舊的(有最新版)
Quick Start
create a new environment
conda create -n visgpt python=3.8
activate the new environment
conda activate visgpt
prepare the basic environments
pip install -r requirement.txt
download the visual foundation models
bash download.sh
約略需要40G的大小空間
需要一點時間安裝完畢
prepare your private openAI private key
export OPENAI_API_KEY={Your_Private_Openai_Key}
create a folder to save images
mkdir ./image
Start Visual ChatGPT !
python visual_chatgpt.py
:::
記得要在同一層的路徑下執行下面指令
Visual-ChatGPT
建立虛擬環境的好處是可以根據不同專案使用不同版本的套件
避免套件之間的衝突 確保套件相依性的正確性。這邊我選擇在 MacOS 系統下使用 pipenv 來建立虛擬環境
EY*研究院
【Python】隨記:pipenv使用不同版本的python
https://dotblogs.com.tw/Eyelash/Search?q=pip
成功建立虛擬環境並確認 python 版本:
接著在 Terminal 根據虛擬環境輸入對應指令安裝套件:
1.conda
pip install -r requirements.txt
2.pipenv
pipenv install -r requirements.txt
即可安裝對應正確的套件版本
參考資料:
pipenv使用不同版本的python
[Day-02] 專案的 Python 環境設置(如何使用 Pipenv)
填入你的 OpenAi API key
export OPENAI_API_KEY={Your_Private_Openai_Key}
issue 看到有人提 如何改变图片分辨率从512到1024 #145
更改以實驗性質為測試 可能會影響準確度(?)
and replied with traditional chinese
預設需要載入的
(default="ImageCaptioning_cuda:0,Text2Image_cuda:0")
python+python檔案+載入模型+選擇cpu/gpu
Mac 目前看起來是要指定 python3 :
Foundation Model | GPU Memory (MB) |
---|---|
ImageEditing | 3981 |
InstructPix2Pix | 2827 |
Text2Image | 3385 |
ImageCaptioning | 1209 |
Image2Canny | 0 |
CannyText2Image | 3531 |
Image2Line | 0 |
LineText2Image | 3529 |
Image2Hed | 0 |
HedText2Image | 3529 |
Image2Scribble | 0 |
ScribbleText2Image | 3531 |
Image2Pose | 0 |
PoseText2Image | 3529 |
Image2Seg | 919 |
SegText2Image | 3529 |
Image2Depth | 0 |
DepthText2Image | 3531 |
Image2Normal | 0 |
NormalText2Image | 3529 |
VisualQuestionAnswering | 1495 |
Foundation Model 翻譯成繁體中文的列表:(ChatGPT翻譯)
圖片編輯
圖片轉圖片
文字轉圖片
圖片標註
圖片轉 Canny 邊緣檢測
Canny 邊緣檢測與文字轉圖片
圖片轉線畫
線畫與文字轉圖片
圖片轉 Hed 邊緣檢測
Hed 邊緣檢測與文字轉圖片
圖片轉手繪草圖
手繪草圖與文字轉圖片
圖片轉姿態
姿態與文字轉圖片
圖片轉分割
分割與文字轉圖片
圖片轉深度
深度與文字轉圖片
圖片轉法向量
法向量與文字轉圖片
視覺問答
https://blog.aidec.tw/post/microsoft-visual-chatgpt-win10?utm_source=blog&utm_medium=postref
https://zhuanlan.zhihu.com/p/614319329
重新安裝
pip install
已解決
mac m1 似乎要改 requirment
https://github.com/microsoft/visual-chatgpt/issues/149#issuecomment-1465878310
Mon, Mar 13, 2023 11:29 PM
If you cannot open the Visual ChatGPT web interface in Safari, you can try using a different web browser such as Google Chrome or Mozilla Firefox. Sometimes, certain websites or web applications may not be fully compatible with certain web browsers, so switching to a different one may help.
改 localhost
https://github.com/microsoft/visual-chatgpt/issues/235#issuecomment-1475764470
demo.launch(server_name="0.0.0.0", server_port=7868)
Mac 系統 Port 號被佔用的解決方式(Mac Port xxx is already in use)
https://israynotarray.com/other/20220117/241830554/
如何清除系統上被佔用的Port?
https://andy6804tw.github.io/2018/02/28/kill-port-macos/
Mac 找出被佔用的IP及port find IP port usage
https://matthung0807.blogspot.com/2019/11/mac-find-network-port-usage.html
https://github.com/microsoft/visual-chatgpt/issues/152
但圖片編輯的部分 不能運作
已解決,加入 ImageEditing_cpu
作為一名人工智能語言模型,GPT-3.5 的中文理解能力已經相當出色,但它仍然存在一些缺點和挑戰。以下是一些可能的缺點:
總之,雖然GPT-3.5在中文理解方面取得了很大的進展,但仍然需要在語言多樣性、上下文理解、語義模糊和實體識別等方面不斷完善和進步。
以上筆記文字內容由 ChatGPT 共同協作完成