“Unknown layer: Lambda” in tensorflowjs on browser

為{幸葍}努か 提交于 2020-01-14 19:42:27

问题


I am new in machine learning area. i am trying to run python program on browser by converting trained model in tensorflow js.

this attention_ocr is related to OCR written in python. i have generated HDF5/H5 file and converted that in web specific format with tensorflowjs_converter[ref].

I follow all instruction given in this document but at the time of running in browser it throwing me error (refer screenshot)

I am looking for solution to remove this error...!

Referance :

tensorflow.org

How to import a TensorFlow SavedModel into TensorFlow.js

Importing a Keras model into TensorFlow.js


回答1:


Lambda (native code) layers are not supported in TensorFlow.js. You will need to replace it with a custom layer. This is tricky. Here is an example custom layer: https://github.com/tensorflow/tfjs-examples/tree/master/custom-layer



来源:https://stackoverflow.com/questions/50878885/unknown-layer-lambda-in-tensorflowjs-on-browser

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!