nikhilk / node-tensorflow

Node.js + TensorFlow
Apache License 2.0
587 stars 59 forks source link

Support for saved models #31

Open nikhilk opened 6 years ago

nikhilk commented 6 years ago

This is to allow for using the a checkpoint resulting from training (exported to a saved model) for predictions.

This will form the basis for defining the high-level interface - instances in, predictions out.

colocha commented 6 years ago

Hi, we are trying to use your code to open a logistic regression built with tensorflow within node.js. We followed your examples and all is good. The thing is that at the moment, we have a model that is saved in three files: saved_model.pb, variables.data-00000-of-00001 and variables.index. We built the model using tf.estimator.LinearClassifier and saved it using export_savedmodel. We want to read the model and pass some features (categorical mostly) to make predictions from this trained model. How to do it?? Is it possible to do it from the current state of your code??? Any help would be really appreciated.