Closed hmhwe closed 5 years ago
I want to run a POS tagging kera model on a browser using keras.js in react, but it is unable to read the file. Here is the js code
handlePredict() { const model = new Model({ filepath:'example.biln', filesystem: true, gpu: true }) alert('Input'); model.ready().then(() =>model.predict({ input: new Float32Array(samples), })) .then(output => { // outputData is an object keyed by names of the output layers // or `output` for Sequential models // e.g., alert('Predicted value : ' + output[1]); }) .catch(err => { alert(err); }) }
What could be the problem?
I want to run a POS tagging kera model on a browser using keras.js in react, but it is unable to read the file. Here is the js code
What could be the problem?