Closed ibnyusuf closed 3 years ago
This is something to do with the model conversion , @pyu10055 do you know if keras_vggface is supported in tfjs ?
can you try to convert using below command tensorflowjs_converter \ --input_format=tf_saved_model \ --output_format=tfjs_graph_model \ --signature_name=serving_default \ --saved_model_tags=serve \ /mobilenet/saved_model \ /mobilenet/web_model
ans try to load the model using tf.loadGraphModel ?
Thanks a lot, that works! Could you explain what was causing the error?
I can not comment with out knowing what steps you have used to convert model and load.
I used
tensorflowjs_converter --input_format=keras_saved_model --metadata= --quantize_uint8=* C:\Users\user\Documents\Face_Recognition_Tensorflow\model .
to convert the model and
tf.loadLayersModel
to load the model.
The command above to convert the model was produced by the wizard.
if it is from wizard , i have no idea , in general all the saved models are converted using the commands I provided. @pyu10055 is this a bug in wizard or is it expected ?
This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you.
I am attempting to convert a Keras model to a Tensorflow js model using the converter tool. The resulting model is missing weight meta data in the
weightManifest
section of themodel.json
file.Model generation and saving code:
Model conversion code:
Error that I see when attempting to load into React Native app:
If I open the modeel.json file the meta data in the weightsManifest section is missing for these layers. I am not sure if it is an issue with how I saved the model or with the conversion process. However, if I read the saved model back into Python it works fine which makes me suspect the conversion process. Any ideas? Thanks!