Turi Create
Python 環境設定
使用 turi create 前,先設定好 Jupyter Notebook 環境
Turi Create
model 將識別目標物的 label 、大小及坐標
[{'coordinates': {'height': 104, 'width': 110, 'x': 115, 'y': 216}, 'label': 'ball'}, {'coordinates': {'height': 106, 'width': 110, 'x': 188, 'y': 254}, 'label': 'ball'}, {'coordinates': {'height': 164, 'width': 131, 'x': 374, 'y': 169}, 'label': 'cup'}]
利用合成的技巧,用少量的素材產生大量的圖資供 model 訓練用
from PIL import Image # 讀取圖像 im = Image.open("lenna.jpg" im.show() # 放為 128x128 im_resized = im.resize((128, 128)) im_resized.show() # 旋轉 im_rotate = im.rotate(45) im_rotate.show() # 翻轉 out = im.transpose(Image.FLIP_LEFT_RIGHT) out = im.transpose(Image.FLIP_TOP_BOTTOM) out = im.transpose(Image.ROTATE_90) out = im.transpose(Image.ROTATE_180) out = im.transpose(Image.ROTATE_270)
直接下載圖的好用工具
Last updated
Was this helpful?