Hi, I'm trying to convert yolo v3 tensorflow model to dlc file.
first, I have followed this link to convert yolov3 darknet model to tensorflow :https://github.com/jinyu121/DW2TF
second, using tensorflow tools i made the frozen_graph_yolov3.pb file.
and then, I am trying to covert this pb file to DLC file using this command :
snpe-tensorflow-to-dlc --graph frozen_yolov3.pb -i yolov3/net1 1,608,608,3 --out_node yolov3/convolutional59/BiasAdd --out_node yolov3/convolutional67/BiasAdd --out_node yolov3/convolutional75/BiasAdd --dlc yolov3.dlc --verbose
I am getting following error:
. . .
2019-05-09 19:07:18,561 - 89 - DEBUG - DEBUG_TF_OP_NAME_TYPE_PRINT: Operation(yolov3/convolutional75/kernel) [Const])
2019-05-09 19:07:18,561 - 89 - DEBUG - DEBUG_TF_OP_NAME_TYPE_PRINT: Operation(yolov3/convolutional75/bias) [Const])
2019-05-09 19:07:18,561 - 89 - DEBUG - DEBUG_TF_OP_NAME_TYPE_PRINT: Operation(yolov3/convolutional75/Conv2D) [Conv2D])
2019-05-09 19:07:18,561 - 89 - DEBUG - DEBUG_TF_OP_NAME_TYPE_PRINT: Operation(yolov3/convolutional75/BiasAdd) [BiasAdd])
2019-05-09 19:07:18,561 - 87 - DEBUG - DEBUG_TF_SCOPE_PRINT: Scope(yolov3/convolutional75/kernel)
2019-05-09 19:07:18,561 - 89 - DEBUG - DEBUG_TF_OP_NAME_TYPE_PRINT: Operation(yolov3/convolutional75/kernel/read) [Identity])
2019-05-09 19:07:18,561 - 87 - DEBUG - DEBUG_TF_SCOPE_PRINT: Scope(yolov3/convolutional75/bias)
2019-05-09 19:07:18,561 - 89 - DEBUG - DEBUG_TF_OP_NAME_TYPE_PRINT: Operation(yolov3/convolutional75/bias/read) [Identity])
2019-05-09 19:07:22,086 - 393 - WARNING - ERROR_TF_FALLBACK_TO_ONDEMAND_EVALUATION: Unable to resolve operation output shapes in single pass. Using on-demand evaluation!
2019-05-09 19:07:22,087 - 290 - INFO - INFO_ALL_BUILDING_NETWORK:
==============================================================
Building Network
==============================================================
2019-05-09 19:07:22,091 - 313 - INFO - INFO_TF_BUILDING_INPUT_LAYER: Building layer (INPUT) with node: yolov3/net1, shape [1, 608, 608, 3]
2019-05-09 19:11:51,323 - 471 - INFO - INFO_ALL_BUILDING_LAYER_W_NODES: Building layer (Convolution) with nodes:
. . .
2019-05-09 19:16:30,067 - 471 - INFO - INFO_ALL_BUILDING_LAYER_W_NODES: Building layer (ElementWiseMul) with nodes: [u'yolov3/convolutional60/Activation/mul']
2019-05-09 19:16:30,075 - 471 - INFO - INFO_ALL_BUILDING_LAYER_W_NODES: Building layer (ElementWiseMax) with nodes: [u'yolov3/convolutional60/Activation']
2019-05-09 19:16:30,077 - 471 - INFO - INFO_ALL_BUILDING_LAYER_W_NODES: Building layer (ResizeNearestNeighbor) with nodes: [u'yolov3/upsample1']
/snpe-1.19.2/lib/python/converters/tensorflow/layers/resize.py:109: RuntimeWarning: error_code=902; error_message=Layer parameter value is invalid in DSP. Layer yolov3/upsample1:0: Only supports BiLinear resize mode. ; error_component=DSP Runtime; line_no=525; thread_id=140171445737216
align_corners=descriptor.align_corners)
2019-05-09 19:16:30,097 - 471 - INFO - INFO_ALL_BUILDING_LAYER_W_NODES: Building layer (Concatenation) with nodes: [u'yolov3/route2']
2019-05-09 19:16:30,186 - 471 - INFO - INFO_ALL_BUILDING_LAYER_W_NODES: Building layer (Convolution) with nodes: [u'yolov3/convolutional61/Conv2D', u'yolov3/convolutional61/BatchNorm/FusedBatchNorm']
2019-05-09 19:16:42,665 - 471 - INFO - INFO_ALL_BUILDING_LAYER_W_NODES: Building layer (ElementWiseMul) with nodes: [u'yolov3/convolutional61/Activation/mul']
2019-05-09 19:16:42,670 - 471 - INFO - INFO_ALL_BUILDING_LAYER_W_NODES: Building layer (ElementWiseMax) with nodes: [u'yolov3/convolutional61/Activation']
2019-05-09 19:16:42,671 - 471 - INFO - INFO_ALL_BUILDING_LAYER_W_NODES: Building layer (Convolution) with nodes: [u'yolov3/convolutional62/Conv2D', u'yolov3/convolutional62/BatchNorm/FusedBatchNorm']
2019-05-09 19:16:55,908 - 471 - INFO - INFO_ALL_BUILDING_LAYER_W_NODES: Building layer (ElementWiseMul) with nodes: [u'yolov3/convolutional62/Activation/mul']
2019-05-09 19:16:55,912 - 471 - INFO - INFO_ALL_BUILDING_LAYER_W_NODES: Building layer (ElementWiseMax) with nodes: [u'yolov3/convolutional62/Activation']
2019-05-09 19:16:55,914 - 471 - INFO - INFO_ALL_BUILDING_LAYER_W_NODES: Building layer (Convolution) with nodes: [u'yolov3/convolutional63/Conv2D', u'yolov3/convolutional63/BatchNorm/FusedBatchNorm']
2019-05-09 19:17:09,074 - 471 - INFO - INFO_ALL_BUILDING_LAYER_W_NODES: Building layer (ElementWiseMul) with nodes: [u'yolov3/convolutional63/Activation/mul']
2019-05-09 19:17:09,079 - 471 - INFO - INFO_ALL_BUILDING_LAYER_W_NODES: Building layer (ElementWiseMax) with nodes: [u'yolov3/convolutional63/Activation']
2019-05-09 19:17:09,080 - 471 - INFO - INFO_ALL_BUILDING_LAYER_W_NODES: Building layer (Convolution) with nodes: [u'yolov3/convolutional64/Conv2D', u'yolov3/convolutional64/BatchNorm/FusedBatchNorm']
2019-05-09 19:17:22,238 - 471 - INFO - INFO_ALL_BUILDING_LAYER_W_NODES: Building layer (ElementWiseMul) with nodes: [u'yolov3/convolutional64/Activation/mul']
2019-05-09 19:17:22,243 - 471 - INFO - INFO_ALL_BUILDING_LAYER_W_NODES: Building layer (ElementWiseMax) with nodes: [u'yolov3/convolutional64/Activation']
2019-05-09 19:17:22,244 - 471 - INFO - INFO_ALL_BUILDING_LAYER_W_NODES: Building layer (Convolution) with nodes: [u'yolov3/convolutional65/Conv2D', u'yolov3/convolutional65/BatchNorm/FusedBatchNorm']
2019-05-09 19:17:35,810 - 471 - INFO - INFO_ALL_BUILDING_LAYER_W_NODES: Building layer (ElementWiseMul) with nodes: [u'yolov3/convolutional65/Activation/mul']
2019-05-09 19:17:35,820 - 471 - INFO - INFO_ALL_BUILDING_LAYER_W_NODES: Building layer (ElementWiseMax) with nodes: [u'yolov3/convolutional65/Activation', u'yolov3/route3']
2019-05-09 19:17:35,824 - 471 - INFO - INFO_ALL_BUILDING_LAYER_W_NODES: Building layer (Convolution) with nodes: [u'yolov3/convolutional68/Conv2D', u'yolov3/convolutional68/BatchNorm/FusedBatchNorm']
2019-05-09 19:17:50,640 - 471 - INFO - INFO_ALL_BUILDING_LAYER_W_NODES: Building layer (ElementWiseMul) with nodes: [u'yolov3/convolutional68/Activation/mul']
2019-05-09 19:17:50,645 - 471 - INFO - INFO_ALL_BUILDING_LAYER_W_NODES: Building layer (Convolution) with nodes: [u'yolov3/convolutional58/Conv2D', u'yolov3/convolutional58/BatchNorm/FusedBatchNorm']
2019-05-09 19:17:50,688 - 106 - ERROR - Conversion failed: ERROR_TF_INPUT_OPERATION_NOT_FOUND: Input operation not found for yolov3/convolutional58/Conv2D
Any help will be appreciated
Thanks
Hi,
I am having a trouble on using snpe sdk to convert yolov3.
Did you had any progress after this wirte?
If it is, which code did you used for tensorflow version of Yolov3??
Need your help whatever it is.. It works with inceptionV3 which is tutorial of snpe_tensorflow_to_dlc
Thanks,
Chris