Since intel open vino does not directly support keras, I saved keras model in saved_model.pb by using this method https://docs.openvino.ai/latest/openvino_docs_MO_DG_prepare_model_convert_model_Convert_Model_From_TensorFlow.html (using open vino version 2021.4) After that, I converted it to IR (xml and bin) and tested with hello classification.py in development tool (it worked fine, result with 1 image = class id 0 = 100 percent , class id 1 = 0 percent).
Finally I want to use my classification model with one of open model in open vino (etc. person detection). I ran my code like below
I got unsupported model output. I think I know why because my classification has label 0 (person wearing hat) and 1(not wearing hat). However, at the same time person-detection-0201 (https://docs.openvino.ai/2021.4/omz_models_model_person_detection_0201.html) has output id 0 = person. if my classifcation classifiy whether a person is wearing hat or not with this person detection, what should I do? I am lost on this. Do I have to make my own custom object detection.py (or modify from the original object detection.py ,same thing)
final output result (steps):
- I want to see the object detection demo detects a person first with person-detection-0201
- classify whether a person is wearing a hat or not from person-detection-0201