Details:
keras: 2.2.4
tensorflow for training: 2.0.0
converted .h5 file to .pb using tensorflow: 1.6.0
SNPE: snpe-1.19.2
ubuntu-14 with tensorflow: 1.6.0, and python 2.7
I am using this command:
snpe-tensorflow-to-dlc --graph /home/chandan/Documents/snpe/models/output_model.pb --input_dim input_1_2 1,224,224,3 --out_node filtered_detections_2/map/TensorArrayStack/TensorArrayGatherV3 --out_node filtered_detections_2/map/TensorArrayStack_1/TensorArrayGatherV3 --out_node filtered_detections_2/map/TensorArrayStack_2/TensorArrayGatherV3 --dlc /home/chandan/Documents/snpe/models/output_model.dlc --allow_unconsumed_nodes
ERROR:
2019-10-31 13:17:47.249405: W tensorflow/core/framework/op_kernel.cc:1202] OP_REQUIRES failed at function_ops.cc:80 : Internal: Retval[1542] has already been set.
2019-10-31 13:17:47.249526: W tensorflow/core/framework/op_kernel.cc:1202] OP_REQUIRES failed at function_ops.cc:80 : Internal: Retval[1548] has already been set.
2019-10-31 13:17:47.249589: W tensorflow/core/framework/op_kernel.cc:1202] OP_REQUIRES failed at function_ops.cc:80 : Internal: Retval[1547] has already been set.
2019-10-31 13:17:47.249652: W tensorflow/core/framework/op_kernel.cc:1202] OP_REQUIRES failed at function_ops.cc:80 : Internal: Retval[1543] has already been set.
2019-10-31 13:17:47.249711: W tensorflow/core/framework/op_kernel.cc:1202] OP_REQUIRES failed at function_ops.cc:80 : Internal: Retval[1544] has already been set.
2019-10-31 13:17:47.249810: W tensorflow/core/framework/op_kernel.cc:1202] OP_REQUIRES failed at function_ops.cc:80 : Internal: Retval[1594] has already been set.
2019-10-31 13:17:47.249882: W tensorflow/core/framework/op_kernel.cc:1202] OP_REQUIRES failed at function_ops.cc:80 : Internal: Retval[1591] has already been set.
2019-10-31 13:17:47.249956: W tensorflow/core/framework/op_kernel.cc:1202] OP_REQUIRES failed at function_ops.cc:80 : Internal: Retval[1601] has already been set.
2019-10-31 13:17:47.250032: W tensorflow/core/framework/op_kernel.cc:1202] OP_REQUIRES failed at function_ops.cc:80 : Internal: Retval[1599] has already been set.
2019-10-31 13:17:47.250113: W tensorflow/core/framework/op_kernel.cc:1202] OP_REQUIRES failed at function_ops.cc:80 : Internal: Retval[1597] has already been set.
2019-10-31 13:17:47.250249: W tensorflow/core/framework/op_kernel.cc:1202] OP_REQUIRES failed at function_ops.cc:80 : Internal: Retval[1592] has already been set.
2019-10-31 13:17:47.405363: W tensorflow/core/framework/op_kernel.cc:1202] OP_REQUIRES failed at function_ops.cc:80 : Internal: Retval[1595] has already been set.
2019-10-31 13:17:47.425089: W tensorflow/core/framework/op_kernel.cc:1202] OP_REQUIRES failed at function_ops.cc:80 : Internal: Retval[1552] has already been set.
2019-10-31 13:17:47.425139: W tensorflow/core/framework/op_kernel.cc:1202] OP_REQUIRES failed at function_ops.cc:80 : Internal: Retval[1551] has already been set.
2019-10-31 13:17:47.427324: W tensorflow/core/framework/op_kernel.cc:1202] OP_REQUIRES failed at function_ops.cc:80 : Internal: Retval[1554] has already been set.
2019-10-31 13:17:47.427348: W tensorflow/core/framework/op_kernel.cc:1202] OP_REQUIRES failed at function_ops.cc:80 : Internal: Retval[1553] has already been set.
2019-10-31 13:17:47.427414: W tensorflow/core/framework/op_kernel.cc:1202] OP_REQUIRES failed at function_ops.cc:80 : Internal: Retval[1550] has already been set.
2019-10-31 13:17:47.427428: W tensorflow/core/framework/op_kernel.cc:1202] OP_REQUIRES failed at function_ops.cc:80 : Internal: Retval[1549] has already been set.
2019-10-31 13:17:47,435 - 393 - WARNING - ERROR_TF_FALLBACK_TO_ONDEMAND_EVALUATION: Unable to resolve operation output shapes in single pass. Using on-demand evaluation!
2019-10-31 13:19:22,606 - 106 - ERROR - Conversion failed: ElementWise resolver must implement broadcast method.
Hi
For your information SNPE supports only the following frameworks Caffe, Caffe2, ONNXTM, and TensorFlowTM.
Rather than converting the Keras model into TensorFlow and converting it to DLC, we suggest using TensorFlow Framework.
You can go through the below link which lists out all the layers and activation functions supported by SNPE,
https://developer.qualcomm.com/docs/snpe/network_layers.html
Thankyou for response
Hi,
Problem: What command parameters should i give for multiple outputs (as i have [boxes,scores, labels] in my model)?
also for my model the input shape is (? , ?, ?, 3) with name input_1
I updated the version of SNPE as SNPE-1.31.0
I was trying with following command:
snpe-tensorflow-to-dlc --graph /home/chandan/Documents/snpe/models/out_model1.pb --input_dim input_1 1,224,224,3 --out_node filtered_detections/map/TensorArrayStack/TensorArrayGatherV3 --out_node filtered_detections/map/TensorArrayStack_1/TensorArrayGatherV3 --out_node filtered_detections/map/TensorArrayStack_2/TensorArrayGatherV3 --dlc /home/chandan/Documents/snpe/models/out_model1.dlc --allow_unconsumed_nodes
now i am gettting error:
**Configuration for training model:**