tensorflow / tfjs

A WebGL accelerated JavaScript library for training and deploying ML models.
https://js.tensorflow.org
Apache License 2.0
18.51k stars 1.93k forks source link

few issues with tensorflowjs_converter #1603

Closed NeuralBricolage closed 4 years ago

NeuralBricolage commented 5 years ago

TF 2.0 using SavedModel the converter was failing so i fixed couple dependencies and build the local whl made it work with a bunch of limitations - not sure if it's by design or bugs

signature name doesn't appear in json - so i defaulted to predict our function has 3 input arguments - but predict expects 1 so i've arranged them into array the input arguments order is not preserved in json thanks! helena

msektrier commented 5 years ago

Just a remark towards point 3 - the RFC for json allows pre-defined orders only for arrays. Otherwise, there is no guarantee how any parser implementation should process the elements of a set.

pyu10055 commented 5 years ago

@AllAwake Good point we should persist the saved model signature into JSON. For now, you can take a look at the signature by using the saved_model_cli, and find out the node names that are associated with the inputs, and use those names to feed to the predict method.