LoginSignup
2

More than 3 years have passed since last update.

segmentation.gif
凍結グラフから変換します。

DeepLabをトレーニングする方法、凍結グラフとしてエクスポートする方法は下記の記事を参照していただければ。
DeepLabv3+を自前のデータセットで学習させる

手順

1、必要なライブラリを用意

TensorFlow1をインストールしていない場合はインストール。


pip install tensorflow==1.x

Colabの場合。TensorFlow1を選択。


%tensorflow_version 1.x

Core ML Toolsをインストール。


pip install coremltools==4.0

2、変換


import coremltools as ct

input = ct.ImageType(shape=(1, 513, 513, 3))
mlmodel = ct.convert('./frozen_graph.pb',inputs=[input])
mlmodel.save('./deeplabv3')

🐣


お仕事のご相談こちらまで
rockyshikoku@gmail.com

Core MLを使ったアプリを作っています。
機械学習関連の情報を発信しています。

Twitter
Medium

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2