Python影像辨識筆記(十):使用GluonCV快速執行SSD、Faster RCNN、YOLOv3推論

介紹

GluonCV是一個專門用來執行電腦視覺任務的Python套件,功能相當廣泛。在Image Classification, Object Detection, Instance Segmentation, Semantic Segmentation, Pose Estimation, Action Recognition, Object Tracking, Dataset reparation, Distributed Training, Deployment都有不錯的應用。

我也有看到該模組能與OpenCV結合,達成即時Object Dection的功能。

本文將著重在如何透過Pre-train Model推論的部份,Model Training在官方的Tutorial也有詳細的介紹。

安裝gluoncv

# Cuda 10.1pip install --upgrade mxnet-cu101 gluoncv註:如果Cuda版本是10.0,則改成mxnet-cu100conda uninstall hdf5
conda install hdf5

官方教學

GluonCV討論版

Object Dection:

Predict with pre-trained SSD models

Jupyter Notebook

Predict with pre-trained YOLO models

Jupyter Notebook

API Difference between SSD, RCNN, YOLOx, img = data.transforms.presets.ssd.load_test(im_fname, short=512)
x, orig_img = data.transforms.presets.rcnn.load_test(im_fname)
x, img = data.transforms.presets.yolo.load_test(im_fname, short=512

Written by

Machine Learning / Deep Learning / Python / Flutter cakeresume.com/yanwei-liu

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store