Toybrick

标题: 请教SSD_mobilenetV1模型转化报错问题 [打印本页]

作者: superbc    时间: 2020-8-26 10:23
标题: 请教SSD_mobilenetV1模型转化报错问题
本帖最后由 superbc 于 2020-8-26 10:25 编辑

环境:debian10,tensorflow 1.14,rknn-toolkit 1.4.0
转换模型:自己用数据训练的SSD_mobilenetV1模型


转换代码:
rknn.load_tensorflow(tf_pb='./frozen_inference_graph.pb',
                         inputs=['image_tensor'],
                         outputs=['num_detections', 'detection_boxes', 'detection_scores','detection_classes'],
                         input_size_list=[[INPUT_SIZE, INPUT_SIZE, 3]])

报错信息:
E Unknow layer "tensorarraygatherv3"
E Try match TensorArrayGatherV3 Postprocessor/BatchMultiClassNonMaxSuppression/map/TensorArrayStack/TensorArrayGatherV3 failed, catch exception!
E Catch exception when loading tensorflow model: ./frozen_inference_graph.pb!
E Traceback (most recent call last):
E   File "rknn/base/RKNNlib/converter/convert_tf.py", line 668, in rknn.base.RKNNlib.converter.convert_tf.convert_tf.match_paragraph_and_param
E   File "rknn/base/RKNNlib/RKNNnet.py", line 189, in rknn.base.RKNNlib.RKNNnet.RKNNNet.new_layer
E   File "rknn/api/rknn_log.py", line 312, in rknn.api.rknn_log.RKNNLog.e
E ValueError: Unknow layer "tensorarraygatherv3"
E During handling of the above exception, another exception occurred:
E Traceback (most recent call last):
E   File "rknn/api/rknn_base.py", line 374, in rknn.api.rknn_base.RKNNBase.load_tensorflow
E   File "rknn/base/RKNNlib/converter/convert_tf.py", line 767, in rknn.base.RKNNlib.converter.convert_tf.convert_tf.match_paragraph_and_param
E   File "rknn/api/rknn_log.py", line 312, in rknn.api.rknn_log.RKNNLog.e
E ValueError: Try match TensorArrayGatherV3 Postprocessor/BatchMultiClassNonMaxSuppression/map/TensorArrayStack/TensorArrayGatherV3 failed, catch exception!
done
--> Building model
Traceback (most recent call last):
  File "main.py", line 37, in transfer_rknn
    rknn.build(do_quantization=False)
  File "/home/zmlq/.local/lib/python3.7/site-packages/rknn/api/rknn.py", line 231, in build
    inputs = self.rknn_base.net.get_input_layers()
AttributeError: 'NoneType' object has no attribute 'get_input_layers'







作者: leok    时间: 2020-8-27 09:05
tf版本请用1.10.0-1.13.2之间。试试。
作者: superbc    时间: 2020-8-27 10:03
请问这些版本的tf可以在哪里下载。我的tf 1.14.0是在https://github.com/lhelontra/tensorflow-on-arm/releases下载的。里面没有针对debian10的tensorflow 1.13.2。请告知。谢谢!




欢迎光临 Toybrick (https://t.rock-chips.com/) Powered by Discuz! X3.3