bendangnuksung / mrcnn_serving_ready

🛠 Mask R-CNN Keras to Tensorflow and TFX models + Serving models using TFX GRPC & RESTAPI
https://github.com/matterport/Mask_RCNN
MIT License
103 stars 35 forks source link

there is not any files in the folder about serving_model/1/variables. #17

Closed LymanLiuChina closed 5 years ago

LymanLiuChina commented 5 years ago

hello, I executed main.py, but I didn't find any files in /serving_model/1/variables. Is it correct?

bendangnuksung commented 5 years ago

Have you modified the Path variables in user_config.py ?

LymanLiuChina commented 5 years ago

I just modified a little, because I just need serving_model about mask_rcnn_coco.h5. but, in the /serving_model/1/, there is saved_model.pd,but in the /serving_model/1/variables, there isn't any file. this is my directory, image

this is my user_config.py:

image

bendangnuksung commented 5 years ago

Can you show me the full error that you are getting.

huyhoang17 commented 5 years ago

@LymanLiuChina there is no need any files in variables folder. I used tensorflow serving and it's serve my .pb model successfully.

deepakks1995 commented 5 years ago

@LymanLiuChina I faced the same issue, it's because the whole model is frozen at the time of exporting it. So variables folder only contain graph meta data, weights which can be used to restore the graph for training. Since we don't require any training at inference hence we have totally frozen the graph, that's why if you open the saved_model.pb file you will find the network architecture along with the frozen constants of the network. If we don't froze the graph these constants will not appear in the protoBuff file and would be saved in weights file inside variables folder.

LymanLiuChina commented 5 years ago

@LymanLiuChina there is no need any files in variables folder. I used tensorflow serving and it's serve my .pb model successfully.

I got it, thank you!

LymanLiuChina commented 5 years ago

@LymanLiuChina I faced the same issue, it's because the whole model is frozen at the time of exporting it. So variables folder only contain graph meta data, weights which can be used to restore the graph for training. Since we don't require any training at inference hence we have totally frozen the graph, that's why if you open the saved_model.pb file you will find the network architecture along with the frozen constants of the network. If we don't froze the graph these constants will not appear in the protoBuff file and would be saved in weights file inside variables folder.

@LymanLiuChina I faced the same issue, it's because the whole model is frozen at the time of exporting it. So variables folder only contain graph meta data, weights which can be used to restore the graph for training. Since we don't require any training at inference hence we have totally frozen the graph, that's why if you open the saved_model.pb file you will find the network architecture along with the frozen constants of the network. If we don't froze the graph these constants will not appear in the protoBuff file and would be saved in weights file inside variables folder.

h

你能告诉我你得到的完整错误吗?

thank you, @huyhoang17 has told me why this problem arises.

LymanLiuChina commented 5 years ago

@LymanLiuChina there is no need any files in variables folder. I used tensorflow serving and it's serve my .pb model successfully.

I am a novice, I want to deploy the mask model on the server, but according to many online tutorials, I still have many problems. Could you give me a complete Python source code (server and client) for your deployment of the maskrcnmo model? Thank you! this my email: 269779795@qq.com

LymanLiuChina commented 5 years ago

@LymanLiuChina I faced the same issue, it's because the whole model is frozen at the time of exporting it. So variables folder only contain graph meta data, weights which can be used to restore the graph for training. Since we don't require any training at inference hence we have totally frozen the graph, that's why if you open the saved_model.pb file you will find the network architecture along with the frozen constants of the network. If we don't froze the graph these constants will not appear in the protoBuff file and would be saved in weights file inside variables folder.

Thank you. I understand! Have you used this service_model successfully? How do you call this model on the client? Could you share a source code with me?

huyhoang17 commented 5 years ago

@LymanLiuChina hi, you can refer my serving code using gRPC on my github's repo: https://github.com/huyhoang17/matterport-maskrcnn-with-tensorflow-serving/blob/master/serve.py

Hope this answer helps you :smile: Any contributors are welcome :star: :100:

huyhoang17 commented 5 years ago

and thank you @bendangnuksung for your awesome project :+1: :100: it's help me so much, thank you!

bendangnuksung commented 5 years ago

Closing as the original issue has been resolved.