LoginSignup
0
0

More than 5 years have passed since last update.

tensorflow.jsでloadModel

Last updated at Posted at 2018-04-11

概要

tensorflow.jsでloadModelをjsdoでやりたかった。

loadModelの調査

必要なのは、model.jsonとgroup1-shard1of1などのweight
loadModel("model.json")で、モデルとweightを読み込む。

model.jsonをgithubで探す。

安易に、githubで探す。3つ、見つかった。

MNIST
https://github.com/CreativeGP/tensorflowjs-mnist
MNIST
https://github.com/yukagil/tfjs-mnist-cnn-demo
maru,sikaku,sankaku
https://github.com/choonguri/tfjs_shape_inference

model.jsonをperseしてみる。

jsdoの壁

jsdoには、壁が2つある。
1、アセットの1ファイルは、1mbまで。
2、ファイル名が、/assets/c/R/W/c/cRWcMとか、意味不明になる。

挑戦したが、読み込めず。

作戦変更

githubのrawファイルを直接、読み込む。
結果は、cors規制で、撃沈。

成功

rawgitを、採用して、corsをすり抜ける。

成果物

以上。

0
0
0

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
0
0