Open iceharlse opened 2 years ago
在使用您的caattention代码后出现下面问题 File "D:\github\yolov4-tf2\nets\attention.py", line 140, in x_cat_conv_split_h, x_cat_conv_split_w = Lambda(lambda x: tf.split(x, num_or_size_splits=[h, w], axis=2))( TypeError: Exception encountered when calling layer "lambda_3" (type Lambda).
Failed to convert elements of [None, None] to Tensor. Consider casting elements to a supported type. See https://www.tensorflow.org/api_docs/python/tf/dtypes for supported TF dtypes.
Call arguments received by layer "lambda_3" (type Lambda): • inputs=tf.Tensor(shape=(None, 1, None, 16), dtype=float32) • mask=None • training=False
如何解决
老哥,解决了吗?我用ca也有问题
在使用您的caattention代码后出现下面问题 File "D:\github\yolov4-tf2\nets\attention.py", line 140, in
x_cat_conv_split_h, x_cat_conv_split_w = Lambda(lambda x: tf.split(x, num_or_size_splits=[h, w], axis=2))(
TypeError: Exception encountered when calling layer "lambda_3" (type Lambda).
Failed to convert elements of [None, None] to Tensor. Consider casting elements to a supported type. See https://www.tensorflow.org/api_docs/python/tf/dtypes for supported TF dtypes.
Call arguments received by layer "lambda_3" (type Lambda): • inputs=tf.Tensor(shape=(None, 1, None, 16), dtype=float32) • mask=None • training=False
如何解决