Tensorflow.js loading model returns function predict is not defined
问题 When I load a saved model like this (please dont mind the fact that the predict function has no input) const tf = require('@tensorflow/tfjs'); require('@tensorflow/tfjs-node'); const model = tf.loadModel('file://./model-1a/model.json').then(() => { model.predict(); }); I get this error: (node:25887) UnhandledPromiseRejectionWarning: TypeError: model.predict is not a function at tf.loadModel.then (/home/ubuntu/workspace/server.js:10:9) at But when I just create a model instead of loading it