- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi, I have varied input shape images for my tensorflow faster rcnn object detection model, hence using the Shape Inference for resizing my network, but it crashes as below:
ubuntu@ubuntu:~/inference_engine_samples_build/intel64/Release$ ./hello_reshape_ssd /home/ubuntu/Downloads/Invoice_latest_30Sept/IR/frozen_inference_graph.xml /home/ubuntu/Downloads/Invoice_latest_30Sept/Test_18/deanandavid_20191026_page-0001.jpg CPU 1
Resizing network to the image size = [817x463] with batch = 1
munmap_chunk(): invalid pointer
Aborted (core dumped)
But when I tried using a ssd mobilenet v2 coco the network reshaped successfully:
ubuntu@ubuntu:~/inference_engine_samples_build/intel64/Release$ ./hello_reshape_ssd /home/ubuntu/Downloads/ssd_mobilenet_v2_coco_2018_03_29/IR-2/frozen_inference_graph.xml /home/ubuntu/Downloads/Invoice_latest_30Sept/Test_18/deanandavid_20191026_page-0001.jpg CPU 1
Resizing network to the image size = [817x463] with batch = 1
Resulting input shape = [1,3,817,463]
Resulting output shape = [1,1,100,7]
The resulting image was saved in the file: hello_reshape_ssd_output.jpg
Are only ssd models supported for network resize using the Reshape API ?
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Simran,
Thanks for reaching out to us. I can see that you are running hello_reshape_ssd C++ Sample using Faster RCNN Inception V2 model. Inference Engine samples stretch input image to the size of the input layer without preserving aspect ratio. But this behaviour is incorrect for Faster RCNN Inception V2 model.
Further information is available at the following link (Point 1) :
Regards,
Adli
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Understood. So the Shape Inference feature cannot be used in this case?
I used Shape Inference because I have trained my faster rcnn model on varied input shape images, then I created IR with --input_Shape [1,600,1024,3]. After this when I tried inferencing with object_detection_sample_ssd.py I find poor detections, that is, some images the detections are misaligned and some images with no detections.
Is there an another solution to this issue than the shape inference or should I try to resize images before inferencing to [1,600,1024,3] (same as IR input shape) and then give as input to the inference sample as stated in this link https://docs.openvinotoolkit.org/latest/openvino_docs_MO_DG_prepare_model_convert_model_tf_specific_Convert_Object_Detection_API_Models.html#fixed_shape_resizer_replacement
Stated as: If keeping aspect ratio is required, then it is necessary to resize image before passing it to the sample.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Simran,
For Faster RCNN Inception V2 model, I would recommend you to try resizing the image before passing it to the inference engine sample. If you could, please share and post the result here.
Regards,
Adli
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Simran,
This thread will no longer be monitored since we have provided a solution. If you need any additional information from Intel, please submit a new question.
Regards,
Adli
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page