Intel® Distribution of OpenVINO™ Toolkit
Community assistance about the Intel® Distribution of OpenVINO™ toolkit, OpenCV, and all aspects of computer vision-related on Intel® platforms.

Inference on Siamese Triplet Loss Model

Dayax
Beginner
630 Views

Hi,

 

We have a Tensorflow based siamese triplet loss model for face recognition. We converted the model to openvino. But don't how to use it for inference.

The python model looks like this:

siamese_network.layers

[<keras.engine.input_layer.InputLayer at 0x7fa0103ba350>, <keras.engine.input_layer.InputLayer at 0x7f9ff85278d0>, <keras.engine.input_layer.InputLayer at 0x7fa006573890>, <keras.engine.functional.Functional at 0x7fa06fddf0d0>]

 

We then use it for inference as follows using the "Functional" layer:

 

face_embeddings = siamese_network.layers[-1]

emb = face_embeddings.predict(np.expand_dims(image,axis=0))

 

We would like to use the openvino model similarly. Please help.

 

Thanks

0 Kudos
2 Replies
Megat_Intel
Moderator
593 Views

Hi Dayax,

Thank you for reaching out to us.

 

OpenVINO™ toolkit provides various types of learning materials that you may find useful. You can check out the Interactive Tutorials (Python) to help introduce you on how to use the OpenVINO™ toolkit Python API and tools to optimize deep learning inference. For more information on the APIs, you can refer to the OpenVINO Python API page for detailed reference articles on OpenVINO™ toolkit Python APIs.

 

On the other hand, there are also Python Open Model Zoo Demos which are console applications that provide templates to implement inference scenarios and also show you preprocessing and post-processing data for model inference and organizing processing pipelines. Do note that the demos are validated by specific models only. However, you can use both the tutorials and the demos as guides to help you implement your own code based on your needs.

 

Based on your desired inference description, we recommend checking out these Tutorials and Demos to help you with OpenVINO™ toolkit:

 

 

Regards,

Megat


0 Kudos
Megat_Intel
Moderator
533 Views

Hi Dayax,

Thank you for your question. This thread will no longer be monitored since we have provided suggestions. If you need additional information from Intel, please submit a new question.

 

 

Regards,

Megat


0 Kudos
Reply