在内核大小和跨度解码“相同”值时,张量流是否遵循任何通用公式
tf.keras.layers.Conv2D(hiddim_v * 4, kernel_size = 3, stride= 1, "same")
答案 0 :(得分:0)
根据官方文档https://www.tensorflow.org/api_docs/python/tf/nn/convolution
If padding == "SAME": output_spatial_shape[i] = ceil(input_spatial_shape[i] / strides[i])
If padding == "VALID": output_spatial_shape[i] = ceil((input_spatial_shape[i] - (spatial_filter_shape[i]-1) * dilation_rate[i]) / strides[i]).
spatial_filter_shape是内核大小