-
How to Generate Model Files of tfjs (inclubing Structure and Weights) ?
- Need to install python library
tensorflowjs
first.
pip install tensorflowjs
- Then convert models from Keras to Tensorflow.js (refer to here)
- Need to install python library
-
How to Utilize these Model Files?
- Publish Model Files to Web and get the Link of
model.json
. For this case, the URL is : http://mobilenet.purelyvivid_tfjs.nctu.me/tfjs_mobilenet/model.json - Download https://github.com/tensorflow/tfjs-examples . In the folder of
/mobilenet
, open the file namedindex.js
. Modify theconst MOBILENET_MODEL_PATH = ...
to the URL of your model.
-
Confirm your Environment: (could refer to here if your OS is Ubuntu)
Node.js >=8.9 and <9
Yarn
-
Run JS code
yarn yarn watch
- Publish Model Files to Web and get the Link of
-
Notifications
You must be signed in to change notification settings - Fork 0
purelyvivid/tfjs_model
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
Generate and utilize a Pre-trained Model for Tensorflow.js
Topics
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published