1
$\begingroup$

I want to know what is the difference between a these two. For me, they are the same function, so I do not see the reason of existance two same functions.

$\endgroup$
0
$\begingroup$

In TensorFlow 2, they accept different arguments:

tf.nn.convolution(input,...)

Computes sums of N-D convolutions (actually cross-correlation).

input: An (N+2)-D Tensor of type T, of shape [batch_size] + input_spatial_shape + [in_channels]

While the second one is more specific:

tf.nn.conv1d(input,...)

Computes a 1-D convolution given 3-D input and filter tensors.

input: A 3D Tensor.input: A 3D Tensor.

| improve this answer | |
$\endgroup$
  • $\begingroup$ Thank you for your answer. So, basically, both in some case, e.g. 3D tensor input, are computing the same thing? $\endgroup$ – Cepeline Jan 29 at 15:15
  • $\begingroup$ I don't know for sure. I believe you can check it by feeding a 3D tensor to both. $\endgroup$ – homocomputeris Jan 30 at 11:38

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.