|
1、模型利用inception_v3训练
2、将ckpt转换了pb
3、但是在rk3399pro开发板上想要将pb转换成rknn的时候报错如下:
E Catch exception when loading tensorflow model: frozen_graph.pb!
E Traceback (most recent call last):
E File "/usr/local/lib/python3.6/site-packages/tensorflow/python/framework/importer.py", line 418, in import_graph_def
E graph._c_graph, serialized, options) # pylint: disable=protected-access
E tensorflow.python.framework.errors_impl.InvalidArgumentError: NodeDef mentions attr 'explicit_paddings' not in Op<name=Conv2D; signature=input:T, filter:T -> output:T; attr=T:type,allowed=[DT_HALF, DT_BFLOAT16, DT_FLOAT, DT_DOUBLE]; attr=strides:list(int); attr=use_cudnn_on_gpu:bool,default=true; attr=padding:string,allowed=["SAME", "VALID"]; attr=data_format:string,default="NHWC",allowed=["NHWC", "NCHW"]; attr=dilations:list(int),default=[1, 1, 1, 1]>; NodeDef: InceptionV3/InceptionV3/Conv2d_1a_3x3/Conv2D = Conv2D[T=DT_FLOAT, data_format="NHWC", dilations=[1, 1, 1, 1], explicit_paddings=[], padding="VALID", strides=[1, 2, 2, 1], use_cudnn_on_gpu=true](input, InceptionV3/Conv2d_1a_3x3/weights). (Check whether your GraphDef-interpreting binary is up to date with your GraphDef-generating binary.).
E During handling of the above exception, another exception occurred:
E Traceback (most recent call last):
E File "rknn/api/rknn_base.py", line 190, in rknn.api.rknn_base.RKNNBase.load_tensorflow
E File "rknn/base/RKNNlib/converter/convert_tf.py", line 575, in rknn.base.RKNNlib.converter.convert_tf.convert_tf.match_paragraph_and_param
E File "rknn/base/RKNNlib/converter/convert_tf.py", line 458, in rknn.base.RKNNlib.converter.convert_tf.convert_tf._tf_build_acu_layer
E File "rknn/base/RKNNlib/converter/convert_tf.py", line 429, in rknn.base.RKNNlib.converter.convert_tf.convert_tf._tf_acu_param_assign
E File "rknn/base/RKNNlib/converter/convert_tf.py", line 394, in rknn.base.RKNNlib.converter.convert_tf.convert_tf._tf_parse_param
E File "rknn/base/RKNNlib/converter/convert_tf.py", line 401, in rknn.base.RKNNlib.converter.convert_tf.convert_tf._tf_parase_execute
E File "<string>", line 1, in <module>
E File "rknn/base/RKNNlib/converter/convert_tf.py", line 149, in rknn.base.RKNNlib.converter.convert_tf.convert_tf.shape_pick
E File "rknn/base/RKNNlib/converter/tensorflowloader.py", line 200, in rknn.base.RKNNlib.converter.tensorflowloader.TF_Graph_Preprocess.query_tensors
E File "rknn/base/RKNNlib/converter/tf_util.py", line 371, in rknn.base.RKNNlib.converter.tf_util.TFProto_Util.query_tensor
E File "rknn/base/RKNNlib/converter/tf_util.py", line 372, in rknn.base.RKNNlib.converter.tf_util.TFProto_Util.query_tensor
E File "/usr/local/lib/python3.6/site-packages/tensorflow/python/util/deprecation.py", line 454, in new_func
E return func(*args, **kwargs)
E File "/usr/local/lib/python3.6/site-packages/tensorflow/python/framework/importer.py", line 422, in import_graph_def
E raise ValueError(str(e))
E ValueError: NodeDef mentions attr 'explicit_paddings' not in Op<name=Conv2D; signature=input:T, filter:T -> output:T; attr=T:type,allowed=[DT_HALF, DT_BFLOAT16, DT_FLOAT, DT_DOUBLE]; attr=strides:list(int); attr=use_cudnn_on_gpu:bool,default=true; attr=padding:string,allowed=["SAME", "VALID"]; attr=data_format:string,default="NHWC",allowed=["NHWC", "NCHW"]; attr=dilations:list(int),default=[1, 1, 1, 1]>; NodeDef: InceptionV3/InceptionV3/Conv2d_1a_3x3/Conv2D = Conv2D[T=DT_FLOAT, data_format="NHWC", dilations=[1, 1, 1, 1], explicit_paddings=[], padding="VALID", strides=[1, 2, 2, 1], use_cudnn_on_gpu=true](input, InceptionV3/Conv2d_1a_3x3/weights). (Check whether your GraphDef-interpreting binary is up to date with your GraphDef-generating binary.).
请问造成这个问题的原因是什么,是我电脑训练的tensorflow版本为1.14,rk3399pro开发板tensorflow版本为1.10,是版本不兼容吗?但是我之前用cnn写出的模型转换并没有问题。
|
|